⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 ext.ajax.html.svn-base

📁 PHP 知识管理系统(基于树结构的知识管理系统), 英文原版的PHP源码。
💻 SVN-BASE
📖 第 1 页 / 共 3 页
字号:
"GET" if no parameters are being sent, and "POST" if parameters are being sent. Note thatthe method name is case-sensitive and should be all caps.</div></li><li><b>callback</b> : Function (Optional)<div class="sub-desc">Thefunction to be called upon receipt of the HTTP response. The callback iscalled regardless of success or failure and is passed the followingparameters:<ul><li><b>options</b> : Object<div class="sub-desc">The parameter to the request call.</div></li><li><b>success</b> : Boolean<div class="sub-desc">True if the request succeeded.</div></li><li><b>response</b> : Object<div class="sub-desc">The XMLHttpRequest object containing the response data. See http://www.w3.org/TR/XMLHttpRequest/ for details about accessing elements of the response.</div></li></ul></div></li><li><b>success</b> : Function (Optional)<div class="sub-desc">The functionto be called upon success of the request. The callback is passed the followingparameters:<ul><li><b>response</b> : Object<div class="sub-desc">The XMLHttpRequest object containing the response data.</div></li><li><b>options</b> : Object<div class="sub-desc">The parameter to the request call.</div></li></ul></div></li><li><b>failure</b> : Function (Optional)<div class="sub-desc">The functionto be called upon failure of the request. The callback is passed thefollowing parameters:<ul><li><b>response</b> : Object<div class="sub-desc">The XMLHttpRequest object containing the response data.</div></li><li><b>options</b> : Object<div class="sub-desc">The parameter to the request call.</div></li></ul></div></li><li><b>scope</b> : Object (Optional)<div class="sub-desc">The scope inwhich to execute the callbacks: The "this" object for the callback function.Defaults to the browser window.</div></li><li><b>form</b> : Object/String (Optional)<div class="sub-desc">A formobject or id to pull parameters from.</div></li><li><b>isUpload</b> : Boolean (Optional)<div class="sub-dec">True if the form object is afile upload (will usually be automatically detected).<p>File uploads are not performed using normal "Ajax" techniques, that is they are <b>not</b>performed using XMLHttpRequests. Instead the form is submitted in the standard manner with theDOM <tt>&lt;form></tt> element temporarily modified to have its{@link http://www.w3.org/TR/REC-html40/present/frames.html#adef-target target} set to referto a dynamically generated, hidden <tt>&lt;iframe></tt> which is inserted into the documentbut removed after the return data has been gathered.</p><p>The server response is parsed by the browser to create the document for the IFRAME. If theserver is using JSON to send the return object, then the{@link http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.17 Content-Type} headermust be set to "text/html" in order to tell the browser to insert the text unchanged into the document body.</p><p>The response text is retrieved from the document, and a fake XMLHttpRequest objectis created containing a <tt>responseText</tt> property in order to conform to therequirements of event handlers and callbacks.</p><p>Be aware that file upload packets are sent with the content type {@link http://www.faqs.org/rfcs/rfc2388.html multipart/form}and some server technologies (notably JEE) may require some custom processing in order toretrieve parameter names and parameter values from the packet content.</p></div></li><li><b>headers</b> : Object (Optional)<div class="sub-desc">Requestheaders to set for the request.</div></li><li><b>xmlData</b> : Object (Optional)<div class="sub-desc">XML documentto use for the post. Note: This will be used instead of params for the postdata. Any params will be appended to the URL.</div></li><li><b>jsonData</b> : Object/String (Optional)<div class="sub-desc">JSONdata to use as the post. Note: This will be used instead of params for the postdata. Any params will be appended to the URL.</div></li><li><b>disableCaching</b> : Boolean (Optional)<div class="sub-desc">Trueto add a unique cache-buster param to GET requests.</div></li></ul></p><p>The options object may also contain any other property which might be needed to performpostprocessing in a callback because it is passed to callback functions.</p></div></li>        </ul>
        <strong>Returns:</strong>
        <ul>
            <li><code>Number</code><div class="sub-desc">transactionId The id of the server transaction. This may be used to cancel the request.</div></li>
        </ul>
    </div>
                </div>
                        </div>
        </td>
        <td class="msource"><a ext:cls="Ext.data.Connection" ext:member="#request" href="output/Ext.data.Connection.html#request">Connection</a></td>
    </tr>
        <tr class="method-row inherited alt expandable">
        <td class="micon"><a class="exi" href="#expand">&nbsp;</a></td>
        <td class="sig">
        <a id="Ext.Ajax-resumeEvents"></a>
            <b>resumeEvents</b>() : void            <div class="mdesc">
                        <div class="short">Resume firing events. (see <a ext:cls="Ext.util.Observable" ext:member="suspendEvents" href="output/Ext.util.Observable.html#suspendEvents">suspendEvents</a>)</div>
            <div class="long">
                Resume firing events. (see <a ext:cls="Ext.util.Observable" ext:member="suspendEvents" href="output/Ext.util.Observable.html#suspendEvents">suspendEvents</a>)    <div class="mdetail-params">
        <strong>Parameters:</strong>
        <ul><li>None.</li>        </ul>
        <strong>Returns:</strong>
        <ul>
            <li><code>void</code></li>
        </ul>
    </div>
                </div>
                        </div>
        </td>
        <td class="msource"><a ext:cls="Ext.util.Observable" ext:member="#resumeEvents" href="output/Ext.util.Observable.html#resumeEvents">Observable</a></td>
    </tr>
        <tr class="method-row expandable">
        <td class="micon"><a class="exi" href="#expand">&nbsp;</a></td>
        <td class="sig">
        <a id="Ext.Ajax-serializeForm"></a>
            <b>serializeForm</b>(&nbsp;<code>String/HTMLElement form</code>&nbsp;) : String            <div class="mdesc">
                        <div class="short">Serialize the passed form into a url encoded string</div>
            <div class="long">
                Serialize the passed form into a url encoded string    <div class="mdetail-params">
        <strong>Parameters:</strong>
        <ul><li><code>form</code> : String/HTMLElement<div class="sub-desc"></div></li>        </ul>
        <strong>Returns:</strong>
        <ul>
            <li><code>String</code></li>
        </ul>
    </div>
                </div>
                        </div>
        </td>
        <td class="msource">Ajax</td>
    </tr>
        <tr class="method-row inherited alt expandable">
        <td class="micon"><a class="exi" href="#expand">&nbsp;</a></td>
        <td class="sig">
        <a id="Ext.Ajax-suspendEvents"></a>
            <b>suspendEvents</b>() : void            <div class="mdesc">
                        <div class="short">Suspend the firing of all events. (see <a ext:cls="Ext.util.Observable" ext:member="resumeEvents" href="output/Ext.util.Observable.html#resumeEvents">resumeEvents</a>)</div>
            <div class="long">
                Suspend the firing of all events. (see <a ext:cls="Ext.util.Observable" ext:member="resumeEvents" href="output/Ext.util.Observable.html#resumeEvents">resumeEvents</a>)    <div class="mdetail-params">
        <strong>Parameters:</strong>
        <ul><li>None.</li>        </ul>
        <strong>Returns:</strong>
        <ul>
            <li><code>void</code></li>
        </ul>
    </div>
                </div>
                        </div>
        </td>
        <td class="msource"><a ext:cls="Ext.util.Observable" ext:member="#suspendEvents" href="output/Ext.util.Observable.html#suspendEvents">Observable</a></td>
    </tr>
        <tr class="method-row inherited expandable">
        <td class="micon"><a class="exi" href="#expand">&nbsp;</a></td>
        <td class="sig">
        <a id="Ext.Ajax-un"></a>
            <b>un</b>(&nbsp;<code>String eventName</code>, <code>Function handler</code>, <span class="optional" title="Optional">[<code>Object scope</code>]</span>&nbsp;) : void            <div class="mdesc">
                        <div class="short">Removes a listener (shorthand for removeListener)</div>
            <div class="long">
                Removes a listener (shorthand for removeListener)    <div class="mdetail-params">
        <strong>Parameters:</strong>
        <ul><li><code>eventName</code> : String<div class="sub-desc">The type of event to listen for</div></li><li><code>handler</code> : Function<div class="sub-desc">The handler to remove</div></li><li><code>scope</code> : Object<div class="sub-desc">(optional) The scope (this object) for the handler</div></li>        </ul>
        <strong>Returns:</strong>
        <ul>
            <li><code>void</code></li>
        </ul>
    </div>
                </div>
                        </div>
        </td>
        <td class="msource"><a ext:cls="Ext.util.Observable" ext:member="#un" href="output/Ext.util.Observable.html#un">Observable</a></td>
    </tr>
            </table>                <a id="Ext.Ajax-events"></a>        <h2>Public Events</h2>                <table cellspacing="0" class="member-table">            <tr>                <th class="sig-header" colspan="2">Event</th>                <th class="msource-header">Defined By</th>            </tr>                <tr class="event-row inherited expandable">
        <td class="micon"><a class="exi" href="#expand">&nbsp;</a></td>
        <td class="sig">
        <a id="Ext.Ajax-beforerequest"></a>
            <b>beforerequest</b> : (&nbsp;<code>Connection conn</code>, <code>Object options</code>&nbsp;)            <div class="mdesc">
                        <div class="short">Fires before a network request is made to retrieve a data object.</div>
            <div class="long">
                Fires before a network request is made to retrieve a data object.    <div class="mdetail-params">
        <strong style="font-weight:normal;">Listeners will be called with the following arguments:</strong>
        <ul><li><code>conn</code> : Connection<div class="sub-desc">This Connection object.</div></li><li><code>options</code> : Object<div class="sub-desc">The options config object passed to the <a ext:cls="Ext.data.Connection" ext:member="request" href="output/Ext.data.Connection.html#request">request</a> method.</div></li>        </ul>
    </div>
                </div>
                        </div>
        </td>
        <td class="msource"><a ext:cls="Ext.data.Connection" ext:member="#event-beforerequest" href="output/Ext.data.Connection.html#event-beforerequest">Connection</a></td>
    </tr>
        <tr class="event-row inherited alt expandable">
        <td class="micon"><a class="exi" href="#expand">&nbsp;</a></td>
        <td class="sig">
        <a id="Ext.Ajax-requestcomplete"></a>
            <b>requestcomplete</b> : (&nbsp;<code>Connection conn</code>, <code>Object response</code>, <code>Object options</code>&nbsp;)            <div class="mdesc">
                        <div class="short">Fires if the request was successfully completed.</div>
            <div class="long">
                Fires if the request was successfully completed.    <div class="mdetail-params">
        <strong style="font-weight:normal;">Listeners will be called with the following arguments:</strong>
        <ul><li><code>conn</code> : Connection<div class="sub-desc">This Connection object.</div></li><li><code>response</code> : Object<div class="sub-desc">The XHR object containing the response data.See <a href="http://www.w3.org/TR/XMLHttpRequest/">The XMLHttpRequest Object</a>for details.</div></li><li><code>options</code> : Object<div class="sub-desc">The options config object passed to the <a ext:cls="Ext.data.Connection" ext:member="request" href="output/Ext.data.Connection.html#request">request</a> method.</div></li>        </ul>
    </div>
                </div>
                        </div>
        </td>
        <td class="msource"><a ext:cls="Ext.data.Connection" ext:member="#event-requestcomplete" href="output/Ext.data.Connection.html#event-requestcomplete">Connection</a></td>
    </tr>
        <tr class="event-row inherited expandable">
        <td class="micon"><a class="exi" href="#expand">&nbsp;</a></td>
        <td class="sig">
        <a id="Ext.Ajax-requestexception"></a>
            <b>requestexception</b> : (&nbsp;<code>Connection conn</code>, <code>Object response</code>, <code>Object options</code>&nbsp;)            <div class="mdesc">
                        <div class="short">Fires if an error HTTP status was returned from the server.See HTTP Status Code Definitionsfor details of HTTP stat...</div>
            <div class="long">
                Fires if an error HTTP status was returned from the server.See <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html">HTTP Status Code Definitions</a>for details of HTTP status codes.    <div class="mdetail-params">
        <strong style="font-weight:normal;">Listeners will be called with the following arguments:</strong>
        <ul><li><code>conn</code> : Connection<div class="sub-desc">This Connection object.</div></li><li><code>response</code> : Object<div class="sub-desc">The XHR object containing the response data.See <a href="http://www.w3.org/TR/XMLHttpRequest/">The XMLHttpRequest Object</a>for details.</div></li><li><code>options</code> : Object<div class="sub-desc">The options config object passed to the <a ext:cls="Ext.data.Connection" ext:member="request" href="output/Ext.data.Connection.html#request">request</a> method.</div></li>        </ul>
    </div>
                </div>
                        </div>
        </td>
        <td class="msource"><a ext:cls="Ext.data.Connection" ext:member="#event-requestexception" href="output/Ext.data.Connection.html#event-requestexception">Connection</a></td>
    </tr>
            </table>                </div>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -