rejetto forum

If Statement

0 Members and 1 Guest are viewing this topic.

Offline SpiderPig902

  • Occasional poster
  • *
    • Posts: 24
    • View Profile
ok im drawing a total blank.
I set this statement: ShowServerLimits=No
under special:strings.
Now im trying to base a IF THEN statement under that and cant seem to get it after hours
of messing with this thing!
I have this:
            {.if|{.!ShowServerLimits.}|Yes
            Test Worked
            .}

Its suppose to display the "test Worked" only if the "ShowServerlimits" is set to "Yes".

Please help.

Thanks

SP


Offline Mars

  • Operator
  • Tireless poster
  • *****
    • Posts: 2059
    • View Profile
your error is that 'no' is not the false value

any text is true

0 or empty text is false


{.if|no|hello|bad.} and {.if|false|hello|bad.}  return twice HELLO

{.if|0|hello|bad.} and {.if||hello|bad.}  return twice BAD

you have to use

ShowServerLimits=0    or  ShowServerLimits=           for false
ShowServerLimits=No or ShowServerLimits=yes  or ShowServerLimits=anytext_except_0   for  True
« Last Edit: June 15, 2010, 04:11:41 PM by Mars »



Offline Mars

  • Operator
  • Tireless poster
  • *****
    • Posts: 2059
    • View Profile
i reply in me post above
 ;)

topic closed


Offline SpiderPig902

  • Occasional poster
  • *
    • Posts: 24
    • View Profile
Great Thanks.
I changed it to ShowServerLimits=0
 and change the statement to:
{.if|{.!ShowServerLimits.}


and it works perfect.

Thanks

SP


Offline Mars

  • Operator
  • Tireless poster
  • *****
    • Posts: 2059
    • View Profile
just a word:  i  am confuse   ??? , because SP is the symbol of SilentPliz  ;D


Offline SpiderPig902

  • Occasional poster
  • *
    • Posts: 24
    • View Profile

Offline Mars

  • Operator
  • Tireless poster
  • *****
    • Posts: 2059
    • View Profile