Skip to content

Commit cc73ec3

Browse files
committed
Update key-concepts with XDomainRequest limitation
Added this update in order clarify the understanding implied in the sentence 'This limitation does not apply to scripts that are loaded via jQuery's Ajax methods'. This will help the beginner to understand $.ajax does not work seamlessly with every browser, but only with help of some plugins.
1 parent f933bef commit cc73ec3

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

page/ajax/key-concepts.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,9 @@ $.get( "foo.php", function( response ) {
7171

7272
### Same-Origin Policy and JSONP
7373

74-
In general, Ajax requests are limited to the same protocol (http or https), the same port, and the same domain as the page making the request. This limitation does not apply to scripts that are loaded via jQuery's Ajax methods.
74+
In general, Ajax requests are limited to the same protocol (http or https), the same port, and the same domain as the page making the request. This limitation does not apply to scripts that are loaded via jQuery's Ajax methods, except for Internet Explorer 8 and 9.
75+
76+
Since Internet Explorer versions 8 and 9 uses [XDomainRequest](http://msdn.microsoft.com/en-us/library/ie/cc288060(v=vs.85).aspx), which has only limited support to XHR2 implementation. Further reading of [this ticket](http://bugs.jquery.com/ticket/8283) would help understand the relationship between XDomainRequest and jQuery.
7577

7678
The other exception is requests targeted at a JSONP service on another domain. In the case of JSONP, the provider of the service has agreed to respond to your request with a script that can be loaded into the page using a `<script>` tag, thus avoiding the same-origin limitation; that script will include the data you requested, wrapped in a callback function you provide.
7779

0 commit comments

Comments
 (0)