Bug Tracker

Ticket #6829 (closed bug: invalid)

Opened 4 years ago

Last modified 4 years ago

get failure with non standard domain/port

Reported by: paulwratt Owned by:
Priority: undecided Milestone: 1.4.3
Component: ajax Version: 1.4.2
Keywords: get Cc:
Blocking: Blocked by:

Description

$.get(' http://192.168.1.212:2222/some/folder/'), null, function(data){_code_}); doing a remote GET (as above) in the latest jQuery causes an error when the server has no name, just IP address, and non standard port ( http://192.168.1.212:2222/)

It may not be the IP address, but the port.

It may also be present in older versions, I have not checked. (1.4.2 dev version was used)

If this can not be reproduced, I can supply other information as required.

The same code used on a "regular url" failed when moved to a url as described above. jquery was tried as remote server include, and as local server include, with the same result.

Paul

Change History

comment:2 Changed 4 years ago by addyosmani

  • Priority set to undecided
  • Status changed from new to closed
  • Resolution set to invalid

The reason for this failing is that a different port on the same server or website still violates the XHR Cross domain policy. The only way it could work is by either using JSONP (does not support POST requests) or a proxy webservice on the same server.

You'll unfortunately need to use one of the above suggestions (or alternatively a qualified domain name that doesn't use a non-standard port).

Note: See TracTickets for help on using tickets.