Bug Tracker

Modify

Ticket #8194 (closed bug: duplicate)

Opened 2 years ago

Last modified 2 years ago

Ajax code failure on Symbian WRT

Reported by: lars.eggert@… Owned by: lars.eggert@…
Priority: high Milestone: 1.5.1
Component: ajax Version: 1.5
Keywords: Cc: jaubourg
Blocking: Blocked by:

Description

The new Ajax code in 1.5 doesn't work inside the Symbian Web Runtime. (Whereas 1.4.4 and earlier worked fine.)

I have no means to really debug this, but Ajax requests immediately return with an error, with no request ever going out to the server.

Change History

comment:1 Changed 2 years ago by jitter

  • Cc jaubourg added
  • Owner set to lars.eggert@…
  • Status changed from new to pending
  • Component changed from unfiled to ajax
  • Priority changed from undecided to high

Thanks for taking the time to contribute to the jQuery project by writing a bug report.

Can you somehow submit a reduced test case or provide information by other means e.g. detailing what exactly you are doing and what kind of ajax calls are being made.

Did you already try the jQuery WIP version as described in:  How to report bugs to check if the bug hasn't already been fixed?

comment:2 follow-up: ↓ 4 Changed 2 years ago by lars.eggert@…

  • Status changed from pending to new

I'm doing something very simple, i.e.,

$.ajax({
    type: "POST",
    url: "https://example.com/lars/cgi/example",
    complete: complete,
    cache: false,
    timeout: 30000
});

This worked fine in 1.4.4 and earlier. In 1.5, "complete" immediately fires with a status of "error", with no request being made to the server (nothing in the logs.)

No, I haven't tried the WIP version, but will do so now.

comment:3 Changed 2 years ago by lars.eggert@…

The WIP version still has the bug.

comment:4 in reply to: ↑ 2 Changed 2 years ago by jaubourg

Replying to lars.eggert@…:

I'm doing something very simple, i.e.,

$.ajax({
    type: "POST",
    url: "https://example.com/lars/cgi/example",
    complete: complete,
    cache: false,
    timeout: 30000
});

This worked fine in 1.4.4 and earlier. In 1.5, "complete" immediately fires with a status of "error", with no request being made to the server (nothing in the logs.)

No, I haven't tried the WIP version, but will do so now.

What does it output if you add:

error: function( jqXHR, status, error ) {
    console.log( error );
}

If it's "No Transport", then that's probably because you're trying to do a cross-domain request while Symbian WRT doesn't support CORS. The fix for this kind of situation is to set jQuery.support.cors to true before attempting any ajax request.

comment:5 Changed 2 years ago by jitter

  • Status changed from new to pending

comment:6 Changed 2 years ago by lars.eggert@…

  • Status changed from pending to new

I can confirm that setting

jQuery.support.cors = true;

fixes this regression.

comment:7 Changed 2 years ago by jaubourg

  • Status changed from new to closed
  • Resolution set to duplicate
  • Milestone changed from 1.next to 1.5.1

OK, so this is actually a duplicate. Thanks for having confirmed this, Lars.

comment:8 Changed 2 years ago by jaubourg

Duplicate of #8122.

Please follow the  bug reporting guidlines and use  jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.

View

Add a comment

Modify Ticket

Action
as closed
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.