![]() |
|
help displaying copyright and other data - 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: help displaying copyright and other data (/thread-2583.html) |
help displaying copyright and other data - affa - 2008-04-01 I'm not sure why I'm having so many issues tonight. I've searched the forums and the documentation, but am hitting a brick wall. For reference, I'm using the Stopdesign theme and am dealing with image.php I can figure out two different ways to display the title of a image: or But I can't figure out for the life of me how to display other fields like city, state, copyright, and date (well, specifically, I only want to display year). I'm sorry if this has been covered here before... I've looked and didn't find any answers. But I'm also burnt out right now so who knows. Thanks! help displaying copyright and other data - affa - 2008-04-01 I had meant to add... I see in the online docs that there is a function called getCopyright. Fatal error: Call to undefined function: getcopyright() in /home/abc/public_html/xyz/zenphoto/themes/stopdesign/image.php on line 22 which I assume means the function set needs to be required but i'm not savvy enough to be SURE this is what i need to do, nor where in image.php i should be doing such (other than somewhere near the top) help displaying copyright and other data - acrylian - 2008-04-01 The error is correct. But you can do that even easier, simply use the template function help displaying copyright and other data - affa - 2008-04-02 You rock. I like that function. Unfortunately, I'm still having a few related issues: 3 to be exact: while echo getImageData("copyright") all seem to work correctly, getImageData("title") all return nothing. is there something I'm missing? I think there are other functions I can call to get this data (since the Stopdesign theme already has them showing elsewhere) but why doesn't this function work across the board?
(NOTE: I can actually store quotes in the comment/description field... but I actually need to use that for a comment. Best case I figure out how to map to Location and use that for size.) help displaying copyright and other data - acrylian - 2008-04-02
help displaying copyright and other data - sbillard - 2008-04-02 Locationis the IPTC Location field (2#092). All the field mappings are done in the function getImageMetadata() in functions.php. The problem with the quotes is a deficiency in the implementation. We will fix it. help displaying copyright and other data - affa - 2008-04-02 Once again, thank you both.
help displaying copyright and other data - jlang - 2008-04-02 For consistency which seems fairly important to a "zen" project, getImageData should handle these three fields. But from looking through the code, the only place I see getImageData() currently used is in printImageData() and that is itself not used in any of the current themes - so probably noone else noticed or cared. help displaying copyright and other data - acrylian - 2008-04-02 affa: If sbillard says "we will fix it" he is most of the time half done...:-) jlang: I guess that is because the exif stuff was added later. title, date and description are the most important fields and have been there for ever. Perhaps we could indeed clean up that a little sometime... help displaying copyright and other data - affa - 2008-04-02 Wonderful! I might just need to grab a nightly build in a few days. One last, semi-related question. Can anyone explain this time travel problem? CODE: RESULT ?! What ?! help displaying copyright and other data - affa - 2008-04-02 wanted to add - every image seems to result in 1969 (regardless of date which DOES print correctly) when converted to just year. I realize this isn't a ZP issue but if anyone knows what's up please let me know. ALSO - I just filed a bug report in the forum for two bugs I discovered while setting this all up. help displaying copyright and other data - sbillard - 2008-04-02
help displaying copyright and other data - affa - 2008-04-03 bravo. resolved. thanks so much! help displaying copyright and other data - sbillard - 2008-04-03 Regards #3 above: The "get" functions return the raw data. It may have quotation marks in it. Before displaying it you need to expunge these characters. Use the php function `htmlspecialchars()' function to convert characters to something that can be displayed via html. |