little help with a {if} statement
Hi All,
I am wondering if I am trying to add a {if} statement to my subcategory.tpl so that if a person lands on a certain subcategory page it displays a different page instead.
Specifically if a customer lands on $subcat.category id ="270" I want it to show page "264"
this is what I wrote which I thought might work
{if $subcat.categoryid="270"} $cat.categoryid="264"{/if}
I have tried to put it into the subcategory.tpl a variety of ways with no luck. This is the latest
<td class="ColumnTitles" valign="top"><a title="{$subcat.description}" <a href="home.php?cat={ $subcat.categoryid }
"><img src="{if $subcat.icon_url}{$subcat.icon_url}{else}{$xcart_w eb_dir}/default_image.gif{/if}" alt="" />
{if}{$subcat.categoryid="270"} $cat.categoryid="264"{/if}
<br/>
<span class="ItemsList">{ $subcat.category|escape }</span></a>
{if $config.Appearance.count_products eq "Y"}
{if $subcat.product_count}({ $subcat.product_count })
{elseif $subcat.subcategory_count}({ $subcat.subcategory_count })
{else} (0)
{/if}
Am I wrong in thinking that I should be able to make this idea work with a {if} statement?
If not can someone suggest what I need to do to get the page to redirect to the proper location.
As always thanks to all that take the time to answer, it's greatly appreciated.
Best
Scott V
aka fotodog13
xcart gold 4.1.11
apache
__________________
scott v
x cart version 4.1.8 (Unix)
|