Where to edit ALT tag for image?

bigu_c
bigu_c's picture

Joined: 2007-10-28
Posts: 421
Posted: Mon, 2009-09-07 15:49

Default for ALT tag of any image is: Name of image

Quote:
<img src="/d/xxxxx-x/IMAGE-NAME.jpg" width="XXX" height="XXX" alt="IMAGE-NAME"/>

I want find where I can edit this template.

Please help, thank you!

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16504
Posted: Wed, 2009-09-09 21:02

I think, though I'm not 100% sure (I'd have to dig around searching old forum posts)

/modules/core/classes/GalleryTemplate.class
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
bigu_c
bigu_c's picture

Joined: 2007-10-28
Posts: 421
Posted: Thu, 2009-09-10 09:01

I checked and don't see that form.

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16504
Posted: Thu, 2009-09-10 14:03

Ah, dug up this old thread:
http://gallery.menalto.com/node/36533
http://sourceforge.net/tracker/index.php?func=detail&aid=1198718&group_id=7130&atid=357130

Forgot you can edit the templates for this, you probably just want to edit /themes/YourTheme/templates/album.tpl and photo.tpl
http://codex.gallery2.org/Gallery2:Editing_Templates

If you wanted to make other changes to that globally, you'd edit: /modules/core/classes/GalleryPhotoItem.class and
GalleryDerivativeImage.class

____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
bigu_c
bigu_c's picture

Joined: 2007-10-28
Posts: 421
Posted: Fri, 2009-09-11 16:35

I'm sorry, but I'm newbie.

Can you tell me how to edit from:

Quote:
<img src="/d/xxxxx-x/IMAGE-NAME.jpg" width="XXX" height="XXX" alt="IMAGE-NAME"/>

Quote:
<img src="/d/xxxxx-x/IMAGE-NAME.jpg" width="XXX" height="XXX" alt="IMAGE-NAME Pictures"/>

I want this for images on photo pages only.

Thank you!

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16504
Posted: Fri, 2009-09-11 17:05

Can you post a link to a page on your site where you want this change made?

So you just want to append the word Pictures to the existing alt tag?
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
bigu_c
bigu_c's picture

Joined: 2007-10-28
Posts: 421
Posted: Fri, 2009-09-11 17:15

http://www.car-pictures.us/audi/r8/Audi_R8_V10_5_2_FSI_quattro_01.jpg.html

View source you will see:

Quote:
<img src="/download/22462-6/Audi_R8_V10_5_2_FSI_quattro_01.jpg" width="700" height="525" alt="Audi R8 V10 5.2 FSI quattro"/>

I want to change to:

Quote:
<img src="/download/22462-6/Audi_R8_V10_5_2_FSI_quattro_01.jpg" width="700" height="525" alt="Audi R8 V10 5.2 FSI quattro Pictures"/>

... not only for this image.

Hope you understand my mind (sorry for my English)

Thank you!

 
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 16504
Posted: Fri, 2009-09-11 17:26

Edit photo.tpl and add the stuff in bold. It's best to make a local directory and copy photo.tpl into that and make the changes on that file. If you ever upgrade or reinstall your changes will be overwritten if you don't do that.

http://codex.gallery2.org/Gallery2:Editing_Templates

	  {g->image id="%ID%" item=$theme.item image=$image
		    fallback=$smarty.capture.fallback class="%CLASS%"}
	  </div>
	{/g->container}
      {else}
	<div id="photo">
	{g->image item=$theme.item image=$image fallback=$smarty.capture.fallback}
	  {g->image id="%ID%" item=$theme.item image=$image
		    fallback=$smarty.capture.fallback class="%CLASS%" alt="`$theme.item.title` Pictures"}
	  </div>
	{/g->container}
      {else}
	<div id="photo">
	{g->image item=$theme.item image=$image fallback=$smarty.capture.fallback alt="`$theme.item.title` Pictures"}

____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

 
bigu_c
bigu_c's picture

Joined: 2007-10-28
Posts: 421
Posted: Sat, 2009-09-12 13:38

Thank nivekiam,

I changed success :)

Many thanks!