Skip to content

Commit 34b96ed

Browse files
arthurvrtimmywil
authored andcommitted
Ajax: Update notes about jqXHR.success(), .error() and .complete()
Fixes gh-650 Closes gh-677
1 parent 3185657 commit 34b96ed

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

entries/jQuery.ajax.xml

+3-3
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ $.ajax({
3939
</desc>
4040
</property>
4141
<property default="true" name="async" type="Boolean">
42-
<desc>By default, all requests are sent asynchronously (i.e. this is set to <code>true</code> by default). If you need synchronous requests, set this option to <code>false</code>. Cross-domain requests and <code>dataType: "jsonp"</code> requests do not support synchronous operation. Note that synchronous requests may temporarily lock the browser, disabling any actions while the request is active. <strong>As of jQuery 1.8, the use of <code>async: false</code> with jqXHR (<code>$.Deferred</code>) is deprecated; you must use the success/error/complete callback options instead of the corresponding methods of the jqXHR object such as <code>jqXHR.done()</code> or the deprecated <code>jqXHR.success()</code>.</strong></desc>
42+
<desc>By default, all requests are sent asynchronously (i.e. this is set to <code>true</code> by default). If you need synchronous requests, set this option to <code>false</code>. Cross-domain requests and <code>dataType: "jsonp"</code> requests do not support synchronous operation. Note that synchronous requests may temporarily lock the browser, disabling any actions while the request is active. <strong>As of jQuery 1.8</strong>, the use of <code>async: false</code> with jqXHR (<code>$.Deferred</code>) is deprecated; you must use the success/error/complete callback options instead of the corresponding methods of the jqXHR object such as <code>jqXHR.done()</code>.</desc>
4343
</property>
4444
<property name="beforeSend" type="Function">
4545
<argument name="jqXHR" type="jqXHR"/>
@@ -232,7 +232,7 @@ $.ajax({
232232
<ul>
233233
<li>
234234
<strong>jqXHR.done(function( data, textStatus, jqXHR ) {});</strong>
235-
<p>An alternative construct to the success callback option, the <code>.done()</code> method replaces the deprecated <code>jqXHR.success()</code> method. Refer to <code><a href="/deferred.done/">deferred.done()</a></code> for implementation details.</p>
235+
<p>An alternative construct to the success callback option, refer to <code><a href="/deferred.done/">deferred.done()</a></code> for implementation details.</p>
236236
</li>
237237
<li>
238238
<strong>jqXHR.fail(function( jqXHR, textStatus, errorThrown ) {});</strong>
@@ -251,7 +251,7 @@ $.ajax({
251251
</li>
252252
</ul>
253253
<div class="warning">
254-
<p><strong>Deprecation Notice:</strong> The <code>jqXHR.success()</code>, <code>jqXHR.error()</code>, and <code>jqXHR.complete()</code> callbacks are deprecated as of jQuery 1.8. To prepare your code for their eventual removal, use <code>jqXHR.done()</code>, <code>jqXHR.fail()</code>, and <code>jqXHR.always()</code> instead.</p>
254+
<p><strong>Deprecation Notice:</strong> The <code>jqXHR.success()</code>, <code>jqXHR.error()</code>, and <code>jqXHR.complete()</code> callbacks are removed as of jQuery 3.0. You can use <code>jqXHR.done()</code>, <code>jqXHR.fail()</code>, and <code>jqXHR.always()</code> instead.</p>
255255
</div>
256256
<pre><code>
257257
// Assign handlers immediately after making the request,

entries/jQuery.get.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ jqxhr.always(function() {
7575
});
7676
</code></pre>
7777
<h4>Deprecation Notice</h4>
78-
<p>The <code>jqXHR.success()</code>, <code>jqXHR.error()</code>, and <code>jqXHR.complete()</code> callback methods introduced in jQuery 1.5 are <strong>deprecated as of jQuery 1.8</strong>. To prepare your code for their eventual removal, use <code>jqXHR.done()</code>, <code>jqXHR.fail()</code>, and <code>jqXHR.always()</code> instead.</p>
78+
<p>The <code>jqXHR.success()</code>, <code>jqXHR.error()</code>, and <code>jqXHR.complete()</code> callback methods are <strong>removed as of jQuery 3.0</strong>. You can use <code>jqXHR.done()</code>, <code>jqXHR.fail()</code>, and <code>jqXHR.always()</code> instead.</p>
7979
</longdesc>
8080
<note id="same-origin-policy" type="additional"/>
8181
<note id="use-ajaxerror" type="additional" data-title="jQuery.get()"/>

entries/jQuery.getJSON.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ jqxhr.complete(function() {
8787
});
8888
</code></pre>
8989
<h4>Deprecation Notice</h4>
90-
<p>The <code>jqXHR.success()</code>, <code>jqXHR.error()</code>, and <code>jqXHR.complete()</code> callback methods introduced in jQuery 1.5 are <strong>deprecated as of jQuery 1.8</strong>. To prepare your code for their eventual removal, use <code>jqXHR.done()</code>, <code>jqXHR.fail()</code>, and <code>jqXHR.always()</code> instead.</p>
90+
<p>The <code>jqXHR.success()</code>, <code>jqXHR.error()</code>, and <code>jqXHR.complete()</code> callback methods are <strong>removed as of jQuery 3.0</strong>. You can use <code>jqXHR.done()</code>, <code>jqXHR.fail()</code>, and <code>jqXHR.always()</code> instead.</p>
9191
</longdesc>
9292
<note id="same-origin-policy" type="additional"/>
9393
<note id="same-origin-policy-exceptions" type="additional"/>

entries/jQuery.post.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ jqxhr.always(function() {
7777
</code></pre>
7878

7979
<h4>Deprecation Notice</h4>
80-
<p>The <code>jqXHR.success()</code>, <code>jqXHR.error()</code>, and <code>jqXHR.complete()</code> callback methods introduced in jQuery 1.5 are <strong>deprecated as of jQuery 1.8</strong>. To prepare your code for their eventual removal, use <code>jqXHR.done()</code>, <code>jqXHR.fail()</code>, and <code>jqXHR.always()</code> instead.</p>
80+
<p>The <code>jqXHR.success()</code>, <code>jqXHR.error()</code>, and <code>jqXHR.complete()</code> callback methods are <strong>removed as of jQuery 3.0</strong>. You can use <code>jqXHR.done()</code>, <code>jqXHR.fail()</code>, and <code>jqXHR.always()</code> instead.</p>
8181
</longdesc>
8282
<note id="same-origin-policy" type="additional"/>
8383
<note id="use-ajaxerror" type="additional" data-title="jQuery.post()"/>

0 commit comments

Comments
 (0)