Zen Cart Logo
Forums / Templates, Stylesheets, Page Layout / Alt Tags for images please help

Alt Tags for images please help

Views: 3,380

Results 1 to 13 of 13
11 Mar 2010, 11:39 PM
#1
new2u avatar

new2u

Zen Follower

Join Date:
Sep 2009
Posts:
186
Plugin Contributions:
0

Alt Tags for images please help

While checking optimization for seo on my site it shows a few images without any alt tags. How do I add these?
When viewing my page source it show things like
<img src="includes/templates/theme262/images/logo.png" alt="" width="405" height="89" /></a><br />
</div>
Yet the alt= part is not in the header.php file

Where can I edit this?

11 Mar 2010, 11:58 PM
#2
kuroi avatar

kuroi

Totally Zenned

Join Date:
Apr 2006
Location:
London, UK
Posts:
10,475
Plugin Contributions:
11

Re: Alt Tags for images please help

The alt text for that image is defined in the includes/english/header.php file for which your template probably has an over-ride. If that's set but not working, you should take it up with your template supplier, as it will mean that they have broken this core Zen Cart function.

11 Mar 2010, 11:59 PM
#3
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: Alt Tags for images please help

Argg!! theme262 A Template Monster template strikes again

Search this site for Template Monster as this is only the tip of the iceberg of issues you will see

12 Mar 2010, 12:08 AM
#4
new2u avatar

new2u

Zen Follower

Join Date:
Sep 2009
Posts:
186
Plugin Contributions:
0

Re: Alt Tags for images please help

Tell me about it....

12 Mar 2010, 12:10 AM
#5
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: Alt Tags for images please help

Tell me about it....
Sorry, but many of us, especially myself, are testy about their practices

12 Mar 2010, 12:21 AM
#6
new2u avatar

new2u

Zen Follower

Join Date:
Sep 2009
Posts:
186
Plugin Contributions:
0

Re: Alt Tags for images please help

It kills seo... I dont know what they are thinking...

26 Mar 2010, 4:54 PM
#7
new2u avatar

new2u

Zen Follower

Join Date:
Sep 2009
Posts:
186
Plugin Contributions:
0

Re: Alt Tags for images please help

ok I got the logo one to show the alt tag. Now.. another one..

<?php echo zen_draw_separator('pixel_trans.gif', HEADING_IMAGE_WIDTH, HEADING_IMAGE_HEIGHT); ?>

the pixel_trans.gif when generated shows like this in my source
<img src="includes/templates/template_default/images/pixel_trans.gif" alt="" width="3" height="1" /><br />

is there a way that I can specifiy the alt tag for this?

26 Mar 2010, 4:58 PM
#8
new2u avatar

new2u

Zen Follower

Join Date:
Sep 2009
Posts:
186
Plugin Contributions:
0

Re: Alt Tags for images please help

Within /public_html/includes/languages/english/other_images_names.php

I found define('OTHER_IMAGE_TRANPARENT', 'pixel_trans.gif');

I added the tag for it in the alt tag section but it doesn't display

26 Mar 2010, 5:10 PM
#9
new2u avatar

new2u

Zen Follower

Join Date:
Sep 2009
Posts:
186
Plugin Contributions:
0

Re: Alt Tags for images please help

Or if there is a way to remove the alt= from my source so that it doesn't take away from my image seo and keyword density.

26 Mar 2010, 5:36 PM
#10
kuroi avatar

kuroi

Totally Zenned

Join Date:
Apr 2006
Location:
London, UK
Posts:
10,475
Plugin Contributions:
11

Re: Alt Tags for images please help

The zen_draw_separator function isn't used by Zen Cart on the catalog side of the site (the only side that search engines should be spidering).

It's a throwback to table-based layouts when transparent pixels where used to keep things in place. Template Monster went through a phase of using them in place of padding and margins, even on tableless layouts. Goodness knows why - I suspect they had people who hadn't quite grasped proper layout. But I thought they'd got past that now.

Point is, that this function shouldn't be being used anywhere that it matters. So your options are:

  1. re-code the template to remove the function call or
  2. re-write the function not to call the zen_image function that inserts the alt

However, that alt is probably doing you more good than harm. It's impact on the code to content ratio will be miniscule. It's absence would mean that your page would not validate. I'm guessing that if there's any effect at all, the latter would have the bigger benefit, but that neither would really be noticed.

29 Mar 2010, 8:57 PM
#11
new2u avatar

new2u

Zen Follower

Join Date:
Sep 2009
Posts:
186
Plugin Contributions:
0

Re: Alt Tags for images please help

Haha. the page doesn't validate as is.. or straight out of the box. I have had to do so much just to get it to this point.

12 Apr 2011, 3:38 PM
#12
vadimzven avatar

vadimzven

New Zenner

Join Date:
Aug 2009
Posts:
26
Plugin Contributions:
0

Re: Alt Tags for images please help

I have similar situation with template theme225
My site can't passed the test: W3C HTML Validator Direct.
They are complained on

<td><img src="includes/templates/template_default/images/pixel_trans.gif" alt ... Any suggestion?
12 Apr 2011, 3:48 PM
#13
kuroi avatar

kuroi

Totally Zenned

Join Date:
Apr 2006
Location:
London, UK
Posts:
10,475
Plugin Contributions:
11

Re: Alt Tags for images please help

... and the answers the same as in my post just above.

Though with the addition that you might want to take this up with Template Monster (they have their own support), but I wouldn't expect a particularly positive response - I just did a quick validation check against some of their recent Zen Cart templates on their own demo site and every one failed.