Boolean value in dict


    Oct 20 2014 | 1:58 pm
    I can turn a Philips Hue off with JavaScript.
    function bang() { ajaxreq = new XMLHttpRequest(); ajaxreq.open("PUT","http://10.0.1.2/api/masayukiakamatsu/lights/1/state"); ajaxreq.send('{"on":false}'); }
    But I can't describe it in a dict object (for maxurl).
    { "http_method" : "PUT", "url" : "http://10.0.1.2/api/masayukiakamatsu/lights/1/state", "post_data" : { "on" : false } }
    false becomes null after saved. "false" and 0 doesn't work well.
    So my question is how to describe a boolean value (true and false) in a dict object.
    Thank you for your advice.

    • Nov 14 2017 | 7:29 pm
      I was struggling with this as well, after a long search I've found the answer right here on the forum. The HUE lights respond now!
      https://cycling74.com/forums/change-dot-in-float-to-comma