If possible, I need to replace the alt='filename' with alt='keyword/description info from a custom field or from the photo description or keywords'
I dont see any straight forward way of doing this after digging around in the templates and classes for a while. Is this possible?
Mark
Posts: 8601
modules/core/classes/GalleryPhotoItem.class and GalleryDerivativeImage.class are where the alt text is rendered.
Posts: 8
thanks mindless, i finally tracked it down. Not too bad to change unless youre using frames. then it gets complicated
Posts: 33
I just added the following to photo.tpl
{g->image id="%ID%" item=$theme.item image=$image fallback=$smarty.capture.fallback class="%CLASS%" alt=$theme.item.keywords} {/g->container} {else} {g->image item=$theme.item image=$image fallback=$smarty.capture.fallback alt=$theme.item.keywords}Posts: 8
Thanks stukoch, Ill give that a try. Part of the issue for me is that I have to parse the image name, decode it into english (such as a photog name and a subject type) and then put all that stuff into the alt tag. Result: A nice long switch statement for both. I was under the impression that the alt tag was already getting place in there but I may have misread the code. Appreciate the heads up
Posts: 8601
if you provide alt=".." in a {g->image ...} it overrides the default alt text.
Posts: 8
Thanks again mindless. You would have thought that was obvious, but its one of the things I didnt try
Posts: 1
Hello,
I try this but I not succesfull. Is any one have a example to show me? or experience of this trip?
Thanks
Posts: 202
thanks mindless and stukoch.
i tried this on PHOTO.tpl and it worked. and i also added <TITLE> attribute in <IMG> and it also worked.
however when i added <TITLE> attribute in ALBUM.tpl it worked but when i try to change this to parent+item it doesn't work.
like if album is top album and it has to child album say 1 and 2.
when we hover on any of this item it shows respective item name.thats fine.
now what i want is, when i hover on 1 it should show top album - 1.
i tried various combinations but failed.
------------------------------------------------------------------------------------------------------------------
www.net4earning.com