×

Discussion Board

Results 1 to 2 of 2
  1. #1
    Registered User
    Join Date
    Mar 2010
    Location
    Turkey
    Posts
    5

    Lightbulb I have a problem with XMLHttpRequest in JS

    The proble is XMLHttpRequest is working with just explorer. I used XMLHttpRequest in my applications in Ovi for updating. But now they arent working. How can I slve this problem. Is not browsers supporting XMLHttpRequest anymore? What can I use for reading a html API's response with JS for WRT Widget.

    I downloaded Widget XMLHttpRequest(from here). It's not working too.

    function httpRequest()
    {
    try{
    var oRequest = new XMLHttpRequest();
    var sURL = "http:/localhost/dovizservice.aspx?i=doviz&kod=usd&tip=1";

    oRequest.open("GET",sURL,false);
    oRequest.setRequestHeader("User-Agent",navigator.userAgent);
    oRequest.send(null)

    if (oRequest.status==200){
    return oRequest.responseText;
    }else{
    return "NOK Httprequest Error.!";
    }
    }catch(e){
    return e;
    }

    }
    Last edited by DaParadoks; 2011-03-18 at 15:08.

  2. #2
    Nokia Developer Moderator
    Join Date
    Mar 2003
    Location
    Lempäälä/Finland
    Posts
    29,166

    Re: I have a problem with XMLHttpRequest in JS

    The example should work just fine, though I'm not so certain on the Url you are using, thus can you exaplain on what is that url supposed to point to ?

Similar Threads

  1. QWebView with Google Map JS API v3
    By pta0007 in forum Qt
    Replies: 1
    Last Post: 2011-03-11, 12:18
  2. Replies: 1
    Last Post: 2011-02-08, 14:41
  3. XMLHttpRequest problem
    By kogan_y in forum Symbian
    Replies: 3
    Last Post: 2009-12-18, 02:46
  4. Replies: 5
    Last Post: 2007-01-31, 09:12
  5. Replies: 2
    Last Post: 2002-06-26, 08:57

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×