Answer the question
In order to leave comments, you need to log in
How to save an image to a temporary cache?
I am writing a library for vk. There, in order to send a picture to the wall, you need to save it to your computer, I do it through the copy (link, my directory) function, because this is not how
new CurlFile ('address of the card on the Internet') comes out, it only comes out like this new CurlFile ( 'own directory on the server/filename.png'). Maybe somehow you can save the picture in a temporary cache, or in some other way you can do it in order to manage with intermediate saving to your directory?
Answer the question
In order to leave comments, you need to log in
You cannot load a remote file through CurlFile, only a local one. Therefore, you are on the right track. First download the file to yourself, then give it to curl
copy(link,'tmp/tmpfile')
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question