jQuery Tutorial


jQuery Example


jQuery References


jQuery with AJAX




What can we do jQuery with Ajax?

jQuery Method is strongly provide method or function for Ajax Development.
jQuery with Ajax include TXT, HTML, XML document data fetch using GET or POST method.

jQuery load() Method

jQuery load function is a very useful and powerful AJAX function. following load function syntax:

Syntax

$(selector).load(url,data,[callback]);
  • url: URL define the universal locator for requested documents.
  • data: Data is optional parameter. It is use to add your data.
  • callback: Callback is optional parameter. It is use to represents a function to be executed whenever effect is completed.

Example:

<script type="text/javascript"> 
$(document).ready(function(){
  $("button").click(function(){
    $("div").load('ajaxfile.txt');
  });
});
</script>
Online Try This Code Your Self....   »

jQuery with AJAX Request

Method Description
$.ajax(options) Load a remote page using an HTTP request.
$(selector).load(url,data,callback) Load URL for requested document to open.
$.get(url,data,callback,type) Load URL for requested document to open using GET.
$.post(url,data,callback,type) Load URL for requested document to open using POST.
$.getScript(url,callback) Load URL for requested JavaScript document to open.

Full Reference of jQuery with AJAX Method Learn all jQuery with AJAX Method References.