i'm using the code above for writing in a file :
require 'vendor/autoload.php';
use Aws\S3\S3Client;
use Aws\S3\Exception\S3Exception;
$client = S3Client::factory(array(
'credentials' => array(
'key' => 'key',
'secret' => 'secret',
)
));
$client->registerStreamWrapper();
$stream = fopen("s3://bucket-name/files/filename.txt", 'w');
fwrite($stream, $message);
fclose($stream);
it works , but i need to write at the end of the file conserving content already writed... i thought using 'w+' was the solution , but noo , plz how can i do that ?
Thanks.
Aucun commentaire:
Enregistrer un commentaire