View Single Post
  #1  
Old 04-06-2015, 12:02 PM
 
keystone keystone is offline
 

X-Adept
  
Join Date: Jul 2006
Location: USA
Posts: 787
 

Default is there a better way to do this?

I have the ReBOOT template installed on my www.uscandleco.com site. I ran the w3c validator on my home page and it gave me around 40 errors. One of them is this
Quote:
Line 1, Column 10949: Duplicate attribute width.
┘co.com/images/T/xctmpH0L3vi.png" width="140" height="140" alt="Outdoor Pillar ┘

the thumbnail template is this...
Code:
{strip} <span itemprop="image" content="{$tmbn_url}"> <img itemprop="image" class="lazy" {if $id ne ''} id="{$id}"{/if} {if !$notlazy} src="{$AltImagesDir}/spacer.gif"{if $image_x ne 0} width="{$image_x}"{/if}{if $image_y ne 0} height="{$image_y}"{/if} data-src="{else}src="{/if} {if $tmbn_url} {$tmbn_url|amp} {else} {if $full_url} {$current_location} {else} {$xcart_web_dir} {/if} /image.php?type={$type|default:"T"}&amp;id={$productid} {/if} " {if $image_x ne 0} width="{$image_x}"{/if} {if $image_y ne 0} height="{$image_y}"{/if} alt="{$product|escape}" title="{$product|escape}" /> </span> {/strip}

Is the if statement not quite right? I have duplicate width and heights on each thumbnail image throughout my entire site.

It seems as if the one set is for the spacer.gif and the other is for the actual thumbnail.

Any suggestions?
__________________
www.uscandleco.com - X-Cart Version 4.7.11 Gold Plus php7.3
mods:
reCaptcha
running on UNIX

www.keystonecandle.com X-Cart Gold Plus - Version 4.7.11 php7.2
mods:
reCaptcha
cdseo pro
running on UNIX
Reply With Quote