Really there is so many concepts and ideas in Ajax and I could just get a glimpse of what dojo seekers end up understanding. Awesome man. Just awesome. I have been using Ajax for a long time now and I can see that dojo has a handful of nice utilities which a developer using AJAX would need. This definitely will make life much easier and maaaannnnn…. m amazed
New bees to ajax will end up learning about the following concepts
xmlhttp.open("POST","ajax_test.asp",true);
xmlhttp.setRequestHeader("Content-type","application/x-www-form-urlencoded"); xmlhttp.send("fname=Henry&lname=Ford");
responseText get the response data as a string
responseXML get the response data as XML data
onreadystatechange Stores a function (or the name of a function) to be called automatically each time the readyState property changes
readyState Holds the status of the XMLHttpRequest. Changes from 0 to 4:
readyState 0: request not initialized
readyState 1: server connection established
readyState 2: request received
readyState 3: processing request
readyState 4: request finished and response is ready
status 200: "OK"
status 404: Page not found
|
And I thought I was better than the new bees as I knew something about success responses, timeouts, error responses, promises etc. Thank god, I am wrong. Going through the list of available topics in dojo alone says how much I had never used and never even thought of using.
<![if !supportLists]>· <![endif]>dojo/request/xhr - The default provider for a browser based platform
<![if !supportLists]>· <![endif]>dojo/request/script - A provider that expects the response to be embedded in a <script> tag.
<![if !supportLists]>· <![endif]>dojo/request/handlers - Handles the data from a response as designated in the handleAs request option. Also provides the ability to register additional types of handlers.
<![if !supportLists]>· <![endif]>dojo/request/registry - Allows for registration of different providers against different URIs.
<![if !supportLists]>· <![endif]>dojo/request/notify - Publishes the dojo/request topics for requests.
<![if !supportLists]>· <![endif]>dojo/Deferred - The base class for managing asynchronous processes.
No comments:
Post a Comment