Directly opening the link shows that download or online information retrieval is very slow. how can this speed up? {Code ...} the following is the running result (it took 17 seconds to endure) & amp; lt; if get_file_contents is used, it takes 18 s & amp; gt; I want to download this image and rename it to j...
Directly opening the link shows that download or online information retrieval is very slow. how can this speed up?
Below is the running result (it took 17 seconds to endure) <如果 使用get_file_contents 用这个函数要 18s>
I want to download this image and rename it as jpg
Reply content:
Directly opening the link shows that download or online information retrieval is very slow. how can this speed up?
Below is the running result (it took 17 seconds to endure) <如果 使用get_file_contents 用这个函数要 18s>
I want to download this image and rename it as jpg
This is equivalent to two downloads, depending on the speed of your server, it will certainly be slow.
Since you want to get the image size, size, and format, it is better not to use php. you can use js to get the image. This way, the computation is all obtained by the client.
Using this function to obtain remote image information is slow.
You can try to useget_file_content
Get, save to local, and thenimagegetsize
To see if it can be faster.