I added a feature to my Zenphoto gallery that uses javascript to show the 'full' size version of the image without reloading the page. (Note: NOT AJAX). It gets the full image url using "getFullImageURL()" and replacing the data inside the DIV on the Image.php page using .innerHTML.
The problem is that I cannot have my "View Full" button change back into a "View Resized" button that actually works because the zenphoto "printDefaultSizedImage(getImageTitle())" function actually spits out the image using I guess echo, instead of placing the resulting string into a variable (returning it).
If it would return the string (<img src="/path/to/file" width="#" height="#" title="blah") instead of writing it, I could use this function to get the "resized image URL" for my code.
I would like to have a function that returns even just the _URL_ of the resized image. I could use getimagesize() in PHP to get the width and height.
This would come in great handy.
So the point of my post: We need a function that returns just the URL of the resized image (if there isn't already one, if so, I just wasted space)
Comments
Started going through all of the function files (since I know PHP)
And found the function getDefaultSizedImage()
Appears to work.
EDIT: You can see it working on this gallery:
exit12.dyndns.org/zp/
http://www.zenphoto.org/trac/wiki/TemplateFunctionsGuide