Is it possible to use an if-then statement in a binding?

Is it possible to use an if-then statement in a binding? I’m trying to make a binding that applies only under certain conditions.

]]>

3 Commentsto Is it possible to use an if-then statement in a binding?

  1. Anonymous says:

    < ![CDATA[

    Yes


    Little example for changing coloir on day names


    if ($ll_day_name == ‘lundi’){


    return 0xffffaa00;}


    else if ($ll_day_name == ‘jeudi’) {


    return 0xffff00e0;}


    else if ($ll_day_name == ‘mercredi’) {


    return 0xffff0000;}


    else {return 0xffffffff ;


    }

    ]]>

  2. Anonymous says:

    < ![CDATA[

    Or


    $ll_day_name in {samedi:0, dimanche:0} ? 0xff00ff00 : 0xffffff00

    ]]>

  3. Anonymous says:

    < ![CDATA[

    Ahhh!! Awesome. I just couldn’t get the syntax right apparently. Thanks a lot 🙂

    ]]>

Leave a Reply

Your email address will not be published. Required fields are marked *