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)
-   -   Is Greater Than X but Less Than X Possible with Smarty? (https://forum.x-cart.com/showthread.php?t=40092)

ReadytoCover 05-28-2008 08:02 AM

Is Greater Than X but Less Than X Possible with Smarty?
 
Hello!

I am trying to add a third category section on my site. Following some previous threads I currently have two categories, seperated like this in their respective .tpl files:

1.
{foreach from=$categories item=c}
{if $c.order_by lt 900}

2.
{foreach from=$categories item=c}
{if $c.order_by gt 900}


I would like to add a third category section, but I can't find if there is a valid way to have order_by gt xx but lt xx.

Is this possible?

Or is it possible to do something like order_by eq 901, 902, 903. etc?

Thanks!

balinor 05-28-2008 08:08 AM

Re: Is Greater Than X but Less Than X Possible with Smarty?
 
{if $c.order_by lt x and $c.order_by gt y}

ReadytoCover 05-28-2008 08:14 AM

Re: Is Greater Than X but Less Than X Possible with Smarty?
 
Ah ha! Worked perfectly thank you!


All times are GMT -8. The time now is 03:50 AM.

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