ZenphotoCMS Forum
Get image cache links - Printable Version

+- ZenphotoCMS Forum (https://forum.zenphoto.org)
+-- Forum: Support (https://forum.zenphoto.org/forum-1.html)
+--- Forum: General support (https://forum.zenphoto.org/forum-4.html)
+--- Thread: Get image cache links (/thread-11103.html)



Get image cache links - jphilbert - 2013-06-02

Is there any way to get the actual link to a image cache?




Get image cache links - acrylian - 2013-06-02

All image functions do that if the image is cached already. Or what do you mean?




Get image cache links - jphilbert - 2013-06-02

I want to know if I can get the internal link to that file.
No the URL put the physical directory.




Get image cache links - acrylian - 2013-06-02

You mean just /cache/? Don't know off hand if we have a separate function for that. Maybe it would help if you tell for what exactly you need it?




Get image cache links - jphilbert - 2013-06-02

/cache// in relation to the actual image.

It may be faster to access the file directly than to access the URL of hundreds of files.
For exampled I notice my plugin works faster when it uses links that utilizes the actual path than when it uses a URL.

and yes I did a few tests its a bit slower. Funny thing is full size images go faster than the small cache images that WAY smaller... just trying to get every once of speed




Get image cache links - acrylian - 2013-06-02

Then you should use the image get function respectively class methodes. Otherwise you get into trouble if things are changed internally. Also this way you make sure you access images that have been cached.




Get image cache links - sbillard - 2013-06-02

If you mean the server link to the image you can get that by replacing WEBPATH with SERVERPATH in the link the functions return.

But what will you do with that link? Only the PHP code can deal with the result, WEB browsers cannot display from it.




Get image cache links - jphilbert - 2013-06-03

Its not for the web-browser PHP code pulls the images for another reason its just way faster that way.