View Single Post
  #2  
Old 11-17-2005, 01:04 PM
 
balinor balinor is offline
 

Veteran
  
Join Date: Oct 2003
Location: Connecticut, USA
Posts: 30,253
 

Default

Be VERY careful when you are working with {if} tags. If you don't include the brackets, you could really mess your site up. Instead of all of those comment tags, just put a comment at the beginning and the end of the code, like this:

Code:
{*{if $product.weight ne "0.00"}<TR><TD width="30%">{$lng.lbl_weight}</TD><TD nowrap><SPAN id="product_weight">{$product.weight}</SPAN>{$config.General.weight_symbol}</TD></TR>{/if}*}

That will tell X-Cart to skip the whole thing, and won't leave a blank spot where the weight is supposed to be. No need for it to waste time running the {if} statement if there is nothing to process

FYI, this is how you can hide anything on any page. Just be sure to get both the opening and closing {if} tags.
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote