×

Discussion Board

Results 1 to 4 of 4
  1. #1
    Registered User
    Join Date
    Sep 2010
    Posts
    13

    Ajax calls failing (WRT, Prototype, 5800)

    Hi

    Embarking on WRT development and appear to have hit a problem. So far I have been launching an application and accessing the GPS fine, but I'm having an issue making HTTP calls to any server. My main point of reference so far in this regard has been this page.

    What I'm seeing on my 5800 is that the call returns quickly, invokes the success handler, and has empty responseText. These are the exact symptoms that I get when running the same page under Firefox on a PC when pointing to a server different to that which served the script. If I modify my widget page to access localhost and run it accordingly on my local PC host then it works fine - this indicates that my code is fine and it's simply failing to access the URL. (Also, I've tried various configurations of Ajax.Update and Ajax.Request, constructing the request in various ways and applying response handlers in various ways as well, all with the same outcome.)

    Also, when running the widget on the 5800, no connection menu appears (ie asking me to choose between wi-fi/mobile/etc connection points), which also appears to suggest that something's preventing my HTTP request getting anywhere. On starting the widget I do get a user permission request asking for access to positioning (when that code's included) along with access to user data and accessories, but not for access to network resources.

    I assume I've missed some trivial setting to request permission, or something similar, but the page I linked to above doesn't mention anything along these lines, nor indeed does anything else I've found.

    Can anyone point out a stupid mistake here?

    Thanks

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

    Re: Ajax calls failing (WRT, Prototype, 5800)

    did you include <key>AllowNetworkAccess</key> in your info.plist ?

  3. #3
    Registered User
    Join Date
    Sep 2010
    Posts
    13

    Re: Ajax calls failing (WRT, Prototype, 5800)

    Quote Originally Posted by symbianyucca View Post
    did you include <key>AllowNetworkAccess</key> in your info.plist ?
    Nope! That sounds a pretty likely culprit and just what I expected.

    Thankyou for the swift response. For some reason I failed to find the documentation of plist keys last night (here, for anyone else who wants it) - I guess my googling abilities take a nose dive in the small hours of the morning

  4. #4
    Registered User
    Join Date
    Sep 2010
    Posts
    3

    Ajax calls failing (WRT, Prototype)

    Hi, I'm new application development wrt and now I have a problem with ajax call to a page located on my localhost, the ResponseText is empty. What could cause this problem?

    Thanks.

Similar Threads

  1. Wrt + Flash Lite + API Bridge does not work fine for upload file on 5800 and 5530
    By yhalka in forum [Archived] Flash Lite on Nokia Devices
    Replies: 8
    Last Post: 2010-07-21, 07:21
  2. AJAX Remote calls?
    By aiveldesign in forum Symbian
    Replies: 8
    Last Post: 2010-06-20, 01:07
  3. Aborting Ajax calls using XMLHttpRequest.abort();
    By JasperGoes in forum Symbian
    Replies: 2
    Last Post: 2010-04-19, 12:47
  4. Replies: 2
    Last Post: 2009-05-29, 23:27

Posting Permissions

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