Notice: The Monaca & Onsen UI Community Forum is shutting down.

For Onsen UI bug reports, feature requests and questions, please use the Onsen UI GitHub issues page. For help with Monaca, please contact Monaca Support Team.

Thank you to all our community for your contributions to the forum. We look forward to hearing from you in the new communication channels.

Why cant I connect outside?



  • I added this code
    function button(who, state)
    {
    console.log(‘button:’);
    var xhr = new XMLHttpRequest();
    var body = 'who ’ + who + "\nstate " + state;
    xhr.open(“POST”, ‘http://192.168.171.1/submit’, true);
    xhr.setRequestHeader(‘Content-Type’, ‘application/x-www-form-urlencoded’);
    xhr.send(body);
    }

    for onclick of a simple button. It works fine in browser, why it dont work in Monaco IDE ?
    All I see in console log is
    button:
    try - catch dosnt catch any errors too