|
Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon. |
|
View previous topic :: View next topic |
Author |
Message |
paiper Smarty n00b
Joined: 28 Sep 2003 Posts: 1
|
Posted: Sun Sep 28, 2003 11:28 am Post subject: Operators {if} |
|
|
I have a problem, when I want to use an operator in an if.
For example:
{if $fc == "Admin"} ... that works
.....
{/if}
but:
{if $fc== "Admin" OR $fc== "Moderator"} .... doesn't work
......
{/if}
Why? |
|
Back to top |
|
Troublegum Smarty Rookie
Joined: 07 Sep 2003 Posts: 33 Location: Germany
|
Posted: Sun Sep 28, 2003 1:02 pm Post subject: |
|
|
Be sure you have blanks before and after operators (==, !=, AND, OR, ||, &&, and so on). So it is:
{if $fc == "Admin" OR $fc == "Moderator"} |
|
Back to top |
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|