HPCloud-PHP  1.2.0
PHP bindings for HPCloud and OpenStack services.
 All Classes Namespaces Files Functions Variables Pages
streams-tutorial-example.php File Reference

Go to the source code of this file.

Variables

 $ini = parse_ini_file(getenv('HOME') . '/.hpcloud.ini')
 $settings
 $newfile = fopen('swift://Example/my_file.txt', 'w')
if(file_exists('swift://Example/my_file.txt')) $file = file_get_contents('swift://Example/my_file.txt')
print $file PHP_EOL
 $cxt

Variable Documentation

$cxt
Initial value:
stream_context_create(array(
'swift' => array(
'account' => $ini['account'],
'key' => $ini['secret'],
'tenantid' => $ini['tenantId'],
'endpoint' => $ini['url'],
),
))

Definition at line 31 of file streams-tutorial-example.php.

Referenced by StreamWrapper\cxt(), PHPStreamTransport\doRequest(), and PHPStreamTransport\doRequestWithResource().

if (file_exists('swift://Example/my_file.txt')) $file = file_get_contents('swift://Example/my_file.txt')

Definition at line 28 of file streams-tutorial-example.php.

Referenced by CURLTransport\fetchHeaders(), and Container\save().

$ini = parse_ini_file(getenv('HOME') . '/.hpcloud.ini')

Definition at line 8 of file streams-tutorial-example.php.

$newfile = fopen('swift://Example/my_file.txt', 'w')

Definition at line 18 of file streams-tutorial-example.php.

$settings
Initial value:
array(
'account' => $ini['account'],
'key' => $ini['secret'],
'tenantid' => $ini['tenantId'],
'endpoint' => $ini['url'],
)

Definition at line 9 of file streams-tutorial-example.php.

print $file PHP_EOL