Sina's SAE is in a secure period and does not support the SAE that uploads local files directly.
That is, you cannot select files by selecting the File button, after clicking Submit, the file cannot be successfully submitted to the SAE cloud server. Need to pass Sae Provided by Storage Sotrage API interface uploads local files SAE Sto Rage Storage file to achieve this effect!!
The following is a step through the picture to explain:
1. Open our SAE application in service management here you can see storage
2. Then click Storage to go in and see the following screen
3. Click on the new domain name to start, this domain is used to store the future of our uploaded files, create a good after you can click on domain management to view our created domain
4. All have, now only owe us by writing procedures to this domain storage data, I use PHP language, other language principle is the same!
FileExists ($domain, $filename) = = True) {//Determine if the file already exists echo "Image already exists, please re-upload!
"; }else{$filename = $_files["File" ["name"]; $storage->upload ($domain, $filename, $_files[file][tmp_name]); echo "Image upload Successful!
"; echo "";}}else{echo "Incorrect number of pictures, upload failed!
"; }}?><title></title>
Look under: A little card everyone can put code to test their own machine on the run under
How do we access this through the program we store in domain Picture of that?
What's next is showimage.php
!--? php$sae_storage = new Saestorage (); $domainName = "Kepuna"; $listArray = $sae _storage--->getlist ($domainName); foreach ($listArray as $image) {echo "";}?
methods There are many more, I'm just one of them, you can refer to the
span> http://apidoc.sinaapp.com/class-SaeStorage.html The official documentation for the SAE everyone, it's easy!
Below are all the pictures in my domain
Copyright notice: This article is the original article of Bo Master , not reproduced without the permission of the blogger.
Above describes the sae-upload local images to the storagephp version of SAE, including aspects of the content, I hope to be interested in PHP tutorial friends helpful.