How to Use Ext. Ajax: How to Use Ext. Ajax

Source: Internet
Author: User

How to Use Ext. Ajax: How to Use Ext. Ajax
Ext. Ajax. request ({// ajax request
Url: 'account/SysArea/InsertRoot ', // request URL
Params: record. data. attributes, // list of parameters
Success: function (response) {// callback function after successful operation


Var _ o = Ext. decode (response. responseText); // parse

}

});


The following are some attributes and Methods

Config options Ext. data. Connection
View sourcecors: Boolean 'true' indicates that CORS support for XHR objects is enabled (Cross-Origin Resource Sharing)... Ext. data. Connection
View sourcedisableCachingParam: String when the request cache is disabled by append parameters, the append parameter name... Ext. util. Observable
View sourcelisteners: A Configuration Object of the Object. It contains one or more event processing functions and is added to the Object during Object initialization. ... Ext. data. Connection
View sourcewithCredentials: Boolean when this parameter is set to 'true', The XHR object attribute withCredentials = true... Defined ByProperties Ext. Ajax is set.
View sourceautoAbort: Specifies whether a new Boolean request interrupts all incomplete requests. ... Ext. Ajax
View sourcedefaultHeaders: Object

An object that contains the request header information will be added to each request sent using the current object.

Ext. Ajax
View sourcedisableCaching: Boolean

If it is true, a cache-buster (cache killer) will be added to the GET request ). The default value is true.

Ext. Ajax
View sourceextraParams: an Object with a property value, used to add additional parameters to each request sent using the current Object. ... Ext. util. Observable
View sourcehasListeners: ObjectREADONLY this object contains keys for any event with a listener. Listeners can be set directly on the instance, in its class or parent class (through observe), or on the MVC EventBus. The value of this object is true (a non-zero number) and false (0 or undefined ). They do not mean the exact listening... Ext. util. Observable
View sourceisObservable: Boolean is set to true in this class to identify an object as an instantiated Observable or its subclass. ... Ext. Ajax
View sourcemethod: String

The default HTTP request method. Note that this configuration item is case sensitive and all letters should be in uppercase. (If you have not set this configuration item but there is a request parameter, it will be used."POST"Otherwise"GET".).

Ext. Ajax
View sourcetimeout: Number

The request timeout time, in milliseconds. The default value is 30000.

Ext. Ajax
View sourceurl: the default URL used when a String sends a request to the server. ... Defined ByMethods Ext. data. Connection
View sourceabort ([Object request]) interrupts an ongoing request... Ext. data. Connection
View sourceabortAll () interrupts all ongoing requests... Ext. util. Observable
View sourceaddEvents (Object/String... eventNames) adds a specified event to the list of events that this Observable may trigger. ... Ext. util. Observable
View sourceaddListener (String/Object eventName, [Function fn], [Object scope], [Object options]) adds an event processing Function to this Object, for example, myGridPanel. on ("mouseover", this. onMouseOver, this); this method can also pass a single parameter, which is a configuration object that contains the attributes of multiple specified events. Example:... Ext. util. Observable
View sourceaddManagedListener (Ext. util. observable/Ext. element item, Object/String ename, Function fn, Object scope, Object opt) to any Observable Object (or Ext. add a listener. When the component is destroyed, the listener is automatically removed... ext. util. observable
View sourceclearListeners () removes all listeners of this object, including managed listeners... Ext. util. Observable
View sourceclearManagedListeners () removes all managed listeners of this object... Ext. util. Observable
View sourceenableBubble (String/String [] eventNames) by calling this. getBubbleTarget () (if any) allows the events triggered by this Observable object to bubble along the inheritance system without implementation classes in the Observable base class. ... Ext. util. Observable
View sourcefireEvent (String eventName, Object... args): Boolean triggers a specified event using the passed parameter (removing the event name and adding the options Object passed to addListener. ... Ext. util. Observable
View sourcehasListener (String eventName): Boolean checks whether the object has a listener for a specific event or whether the event is blister. ... Ext. data. Connection
View sourceisLoading ([Object request]): Boolean determines whether the request status is incomplete... Ext. util. Observable
View sourcemon (Ext. util. observable/Ext. element item, Object/String ename, Function fn, Object scope, Object opt) shorthand for addManagedListener to any Observable Object (or Ext. add a listener. When the component is destroyed, the listener is automatically removed... ext. util. observable
View sourcemun (Ext. util. Observable/Ext. Element item, Object/String ename, Function fn, Object scope) The short method of removeManagedListener removes the listener added through the mon method. ... Ext. util. Observable
View sourceon (String/Object eventName, [Function fn], [Object scope], [Object options]) adds an event processing Function to this Object using the abbreviated addListener method, for example, myGridPanel. on ("mouseover", this. onMouseOver, this); this method also allows passing a single parameter, which contains the specified... ext. data. connection
View sourceparseStatus (Number status): the Object determines whether the response is successful... Ext. util. Observable
View sourcerelayEvents (Object origin, String [] events, [String prefix]) takes over the selected event from the specified Observable, as if the event was triggered by this. ... Ext. util. Observable
View sourceremoveListener (String eventName, Function fn, Object scope) removes the event handler. ... Ext. util. Observable
View sourceremoveManagedListener (Ext. util. Observable/Ext. Element item, Object/String ename, Function fn, Object scope) removes listeners added using the mon method. ... Ext. data. Connection
View sourcerequest (Object options): the Object sends an HTTP request to a remote server... Ext. util. Observable
View sourceresumeEvents () trigger of the continuation event (see suspendEvents ). ... Ext. data. Connection
View sourcesetOptions (Object options, Object scope): the Object sets various parameters for the request, such as url and params... Ext. util. Observable
View sourcesuincludevents (Boolean queuesuincluded) suspends the trigger of all events. (See resumeEvents)... Ext. util. Observable
View sourceun (String eventName, Function fn, Object scope) removeListener short method to remove the event handler. ... Ext. data. Connection
View sourceupload (String/HTMLElement/Ext. Element form, String url, String params, Object options) Use a hidden iframe to upload form... Defined ByEvents Ext. data. Connection
View sourcebeforerequest (Ext. data. Connection conn, Object options, Object eOpts) triggers this event before the network request of a data Object is sent.
View sourcerequestcomplete (Ext. data. Connection conn, Object response, Object options, Object eOpts) triggers this event when a request is successful... Ext. data. Connection
View sourcerequestexception (Ext. data. Connection conn, Object response, Object options, Object eOpts) triggers this event when the server returns an HTTP Error status value ....

Copyright Disclaimer: This article is an original article by the blogger and cannot be reproduced without the permission of the blogger.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.