![]() |
|
How to get image source path on page created whit image.php file (<img src="")? - 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: How to get image source path on page created whit image.php file (<img src="")? (/thread-9330.html) |
How to get image source path on page created whit image.php file (<img src="")? - Jole - 2011-11-30 How to get image source path ( How to get image source path on page created whit image.php file (<img src="")? - Jole - 2011-11-30 Sorry, web link mistake. An example html source code is from this page: How to get image source path on page created whit image.php file (<img src="")? - acrylian - 2011-11-30 You should escape code correctly. You probably are looking for I suggest to review: Most every "print" function has also a "get" variant. How to get image source path on page created whit image.php file (<img src="")? - Jole - 2011-11-30 Yes, I know it is cached sized image, and I need image source path for that image not for full one. I tried with getFullImageURL but I do not get "pretty" path even if page is cached before. Page html source shows: How to get image source path on page created whit image.php file (<img src="")? - sbillard - 2011-11-30
There is not a means of "forcing" the image to be cached so that you can guarentee a link that is not the image processor. How to get image source path on page created whit image.php file (<img src="")? - Jole - 2011-12-01 I tried that, but even image is cached I do not get image source path of image displayed because I am not using default image size. In "printCustomSizedImageMaxSpace" I used custom values, example: printCustomSizedImageMaxSpace(getBareImageTitle(),725,725); to best fit page design, so my images are 725 x 408 pixels. With getDefaultSizedImage() I get path to image which height is 595, default size I guess (of course if I use printDefaultSizedImage() to make that image first). So I tried with printCustomSizedImage() I hooped I will get right image path but I get error. If you have any suggestions please let me know. How to get image source path on page created whit image.php file (<img src="")? - acrylian - 2011-12-01 If you use "customimage" functions you need to pass parameters to them. Again, "print" functions print html or even html constructs for theming convenience. If you want just the pure date (a path in this case) you have to use the "get" ones. How to get image source path on page created whit image.php file (<img src="")? - Jole - 2011-12-01 I am not quite sure now, what parameters and where to pass them. Can you give me an example for my case? How to get image source path on page created whit image.php file (<img src="")? - acrylian - 2011-12-01 Above you say you don'T use the default size image, so that means your theme uses custom sizes. Then you know what values to pass to the parameters. All parameters are documentated on the functions documentation. On the user guide there is also a tutorial how to read that functions guide. Also again: Quote:` cached sized image Quote:but for getFullImageURL I always get: ' /zp-core/full-image.php?a=folder&i=image.jpg&q=75' Quote:` How to get image source path on page created whit image.php file (<img src="")? - Jole - 2011-12-01 I tried this:
Also I tried this: and this:
and this what you told me So, whatever I try I can not get this How to get image source path on page created whit image.php file (<img src="")? - acrylian - 2011-12-01 Quote:getProtectedImageURL() and getFullImageURL(); and I get the same, this: /zp-core/full-image.php?a=folder&i=image.jpg&q=75 Quote:Also I tried this: Quote:getUnprotectedImageURL() and I get this: What you actuallywant to get is the cached (sized) image url. As said several times you get that by using the "get" custom sized get functions (be it default, custom or custom maxspace). Since that cached image is not cached automatically but on request it always goes first through So How to get image source path on page created whit image.php file (<img src="")? - Jole - 2011-12-01 Thanks for note. I tried with this:
And it works fine, of course I needed to pass parameters (725,725) in my case I use that size of image. Now I get right image path. Thank you again. |