Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

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

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 05-28-2008, 08:02 AM
 
ReadytoCover ReadytoCover is offline
 

Senior Member
  
Join Date: Apr 2008
Posts: 124
 

Default 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!
__________________
x-cart 4.1.9
Reply With Quote
  #2  
Old 05-28-2008, 08:08 AM
 
balinor balinor is offline
 

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

Default Re: Is Greater Than X but Less Than X Possible with Smarty?

{if $c.order_by lt x and $c.order_by gt y}
__________________
Padraic Ryan
Ryan Design Studio
Professional E-Commerce Development
Reply With Quote
  #3  
Old 05-28-2008, 08:14 AM
 
ReadytoCover ReadytoCover is offline
 

Senior Member
  
Join Date: Apr 2008
Posts: 124
 

Default Re: Is Greater Than X but Less Than X Possible with Smarty?

Ah ha! Worked perfectly thank you!
__________________
x-cart 4.1.9
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 01:56 PM.

   

 
X-Cart forums © 2001-2020