Bug Tracker

Opened 11 years ago

Closed 11 years ago

Last modified 5 years ago

#381 closed feature (fixed)

Document global ajax settings

Reported by: joern Owned by:
Priority: major Milestone: 1.1a
Component: ajax Version: 1.1a
Keywords: Cc:
Blocked by: Blocking:

Description

By moving the defaults into a global object, clients could modify these defaults for all following requests. This is already available for timeout, but would be useful for other options, too.

Setting timeout is currently wrapped inside it's own method, that makes it easy to integrate the global timeout setting into the other defaults without breaking the API.

Change History (5)

comment:1 Changed 11 years ago by joern

Version: 1.0b11.0

Hijacking Version 1.0 for anything scheduled for 1.1.

comment:2 Changed 11 years ago by joern

Milestone: 1.1
Version: 1.01.1

comment:3 Changed 11 years ago by joern

  1. Introducde jQuery.ajaxSettings or something similar, contains all defaults currently defined in jQuery.ajax
  2. modify ajaxTimeout() to set jQuery.ajaxSettings.timeout instead of jQuery.timeout
  3. modify jQuery.ajax: s = jQuery.extend({}, jQuery.ajaxSettings, s);
  4. introducde ajaxSetup() or similar: ajaxSetup: function(settings) { jQuery.extend(jQuery.ajaxSettings, settings); }
  5. add test for ajaxSetup

comment:4 Changed 11 years ago by joern

Summary: Move default settings for $.ajax into a global objectDocument global ajax settings

Implemented, but not yet documented.

comment:5 Changed 11 years ago by joern

Resolution: fixed
Status: newclosed

Fixed in SVN.

Note: See TracTickets for help on using tickets.