Question: 1. Can I directly operate on the image in the tmp directory of a space in upyun, and then use the upyun image processing interface to process the image stored in the img directory, download the image in the tmp directory of upyun to my server, process the cropping, and upload it to the img directory of upyun... problem:
1. Can I directly operate on the image in the tmp directory of a space in upyun, and then use the upyun image processing interface to save the processed image to the img directory?
In my current situation, download the image in the tmp directory of upyun to my server, process the cropping, and upload it to the img directory of upyun.
Can I skip this step ??
// $ Fh = fopen ('HTTP: // su.bdimg.com/static/superpage/img/logo_white.png', 'rb ');
// $ Rsp = $ upyun-> writeFile ('/demo/sample_md5.jpeg', $ fh, True, $ opts); // upload an image and automatically create a directory
// Fclose ($ fh );
If the fseek error of php-sdk occurs, is there any other method?
Reply content:
Problem:
1. Can I directly operate on the image in the tmp directory of a space in upyun, and then use the upyun image processing interface to save the processed image to the img directory?
In my current situation, download the image in the tmp directory of upyun to my server, process the cropping, and upload it to the img directory of upyun.
Can I skip this step ??
// $ Fh = fopen ('HTTP: // su.bdimg.com/static/superpage/img/logo_white.png', 'rb ');
// $ Rsp = $ upyun-> writeFile ('/demo/sample_md5.jpeg', $ fh, True, $ opts); // upload an image and automatically create a directory
// Fclose ($ fh );
If the fseek error of php-sdk occurs, is there any other method?
Again cloud currently only provides file upload direct processing of the original image and save the http://wiki.upyun.com/index.php? Title = HTTP_REST_API % E6 % 8E % A5 % E5 % 8F % A3 #. E5.9B. BE. E7.89.87.E5. A4.84.E7.90.86. E6.8E. A5.E5.8F. A3
Interfaces related to file operations (Save As and image processing) are included in the next product plan to ensure stable and efficient services.
I personally use the qiniu api to solve the problem of image size control. UPyun has been useless for a long time. We suggest you try qiniu, And the api call is quite simple.