Skip to main content

Posts

Showing posts from July, 2015

jQuery- Ajax Fast Track

Today I have decided to refresh my knowledge in Ajax with jQuery. The fantastic and easiest way to communicate with server script is using the Ajax Scripts. 

What is Ajax?
Ajax is Asynchronous JavaScript and xml. This is used mainly to exchange data to server and refresh the particular part of the webpage. 

Today most of the web and mobile applications are using the Ajax to communicate with the server. I also love Ajax to use in my applications.

Why jQuery?
Without jQuery Ajax is bit tricky - mean need to write more. I am a lazy guys always find the short way to reach the goal. Lets' dig Ajax via jQuery :)

jQuery-Ajax load() method
Function :- Loading the data from the server and put into a particular element. 
Example : Let's get the data from a file called from demo.txt
This is the demo.txt file
<h2> Let's learn lazy Ajax - jQuery </h2>
<p id="p1">This is Some Paragraph. </p>

My task is to get the whole text in the file
<!DOCTYPE html>
<html&…