Bug Tracker

Modify

Ticket #381 (closed feature: fixed)

Opened 7 years ago

Last modified 2 years ago

Document global ajax settings

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

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

comment:1 Changed 7 years ago by joern

  • Version changed from 1.0b1 to 1.0

Hijacking Version 1.0 for anything scheduled for 1.1.

comment:2 Changed 7 years ago by joern

  • Version changed from 1.0 to 1.1
  • Milestone set to 1.1

comment:3 Changed 7 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 7 years ago by joern

  • Summary changed from Move default settings for $.ajax into a global object to Document global ajax settings

Implemented, but not yet documented.

comment:5 Changed 7 years ago by joern

  • Status changed from new to closed
  • Resolution set to fixed

Fixed in SVN.

Please follow the  bug reporting guidlines and use  jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.

View

Add a comment

Modify Ticket

Action
as closed
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.