#2174 closed bug (fixed)
"Invalid Label" error in FF2 doing JSON AJAX request
Reported by: | dalangalma | Owned by: | |
---|---|---|---|
Priority: | major | Milestone: | 1.2.3 |
Component: | core | Version: | 1.2.2 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
This seems to be a bug introduced in jQuery 1.2.2, since it works in 1.2.1:
I'm making an AJAX call like: $.ajax({
dataType: "json", success: function() { ... }, error: function() { ... }, url: "http://localhost:8080/myurl"
});
Firefox responds with "Invalid Label". If I change the url to "/myurl", it works. In jQuery 1.2.1, both work.
Change History (4)
comment:1 Changed 14 years ago by
comment:2 Changed 14 years ago by
By using POST instead of GET the problem is avoided.
Works:
// Do Ajax $.ajax({ type: 'POST', url: 'http://localhost/path/actions.ajax.php', data: {test:'case'}, dataType: 'json', success: function(result){ alert(result); }, error: function (XMLHttpRequest, textStatus, errorThrown) { alert(errorThrown); } });
Fails:
// Do Ajax $.ajax({ url: 'http://localhost/path/actions.ajax.php', data: {test:'case'}, dataType: 'json', success: function(result){ alert(result); }, error: function (XMLHttpRequest, textStatus, errorThrown) { alert(errorThrown); } });
comment:3 Changed 14 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
Ok, this should be fixed with [4476]. See the changeset for details. This change essentially returns the line to the way it was in 1.2.1 which was working.
Note: See
TracTickets for help on using
tickets.
Here is use case that breaks in jquery-1.2.2 and Firefox Let's assume the form tag is generated dynamically and javascript is static and in separate file.