Log in

View Full Version : IF - the line of my life ;)


rogersnm
05-22-2006, 07:00 PM
In a template do you know how to get an if that will do that:

if $totalchatters > 0

if i type that in it just says i have dodgy code in my template....

basically i need an if that activates when the value of $totalchatters is more than 0

Any Ideas?

Regards,
Nick.

amykhar
05-22-2006, 07:02 PM
<if condition="$totalchatters>0">

rogersnm
05-22-2006, 07:04 PM
hmm thats what i typed in first xD

amykhar
05-22-2006, 07:04 PM
It only works if the variable is in scope for the template.

rogersnm
05-27-2006, 06:58 PM
which it is lol

SaintDog
05-27-2006, 07:24 PM
Have you tried using:

<if condition="$totalchatters != 0">


If so and it doesn't work either, try posting the information here for the coding and let's see what we can do about it :).

rogersnm
05-28-2006, 05:11 AM
no,no, i it works it's just i swear i typed that one in......

maybe i out a space in it..

Paul M
05-28-2006, 10:30 AM
$totalchatters sounds familiar, working on a flashchat mod by any chance ;)

rogersnm
05-28-2006, 12:34 PM
how did you guess ;)

It just adds a box at the top if there are any people in the chatroom :D