Wednesday, February 18, 2015

AJAX Learning

AJAX
========
html, css -> Presentation
DOM -> Interaction with data
XML, JSON -> Data Transfer
XMLHttpRequest -> Asynchronous communication b/w browser & server

XMLHttpRequest
=============
It performs following operations:

Sends data from the client in the background
Receives the data from the server
Updates the webpage without reloading it.

XMLHttpRequest Objects
onReadyStateChange
readyState (range 0 to 4)
reponseText
responseXML

XMLHttpRequest Methods
void open(method, URL)
void open(method, URL, async)
void open(method, URL, async, username, password)
void send()
void send(string)
setRequestHeader(header,value)