X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Changing design (https://forum.x-cart.com/forumdisplay.php?f=51)
-   -   Help with url conditional (https://forum.x-cart.com/showthread.php?t=36656)

taponitrof 01-10-2008 05:25 AM

Help with url conditional
 
Hi,

I want to create a conditional statement based on the url/page displayed. In this case, the home.php page.

I created this statement but it doesn't work.

{if $http_location eq "http://www.mountainhomebuildingproducts.com/home.php"}
<td>test</td>
{/if}

When the url is loaded, the conditional html does not display. What am I doing wrong?

Thanks

balinor 01-10-2008 05:58 AM

Re: Help with url conditional
 
Use this:

{if $main eq "catalog" and $current_category.category eq ""}

show only on home page

{/if}

taponitrof 01-10-2008 06:03 AM

Re: Help with url conditional
 
Thanks! That worked perfectly.


All times are GMT -8. The time now is 11:28 AM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.