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)
-   -   Adding an OR statement (https://forum.x-cart.com/showthread.php?t=27476)

bedstar 12-19-2006 02:34 PM

Adding an OR statement
 
Hi All

Could someone tell me the structure for an OR statement

i.e

{if $cat eq '277' OR '278'} do this action {/if}

Im not quite sure how to write it

thanks

john
Xcart 3x

PhilJ 12-19-2006 02:51 PM

Re: Adding an OR statement
 
try

Code:

{if $cat eq '277' || $cat eq '278'}

inebriate 12-19-2006 06:17 PM

Re: Adding an OR statement
 
you can use "or" or "||" whichever you are more comfortable with...but you need to add "$cat eq" to the latter half of your statement


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

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