/home/techb158/immovalet.ca/report/bower_components/datatables/examples/server_side
NameSizeModeActions
scripts/-0777rm
custom_vars.html116170666editdlrm
defer_loading.html129420666editdlrm
editable.html123630666editdlrm
ids.html113920666editdlrm
jsonp.html116950666editdlrm
object_data.html118060666editdlrm
pipeline.html175000666editdlrm
post.html112260666editdlrm
row_details.html136010666editdlrm
select_rows.html124730666editdlrm
server_side.html166460666editdlrm
Edit: /home/techb158/immovalet.ca/report/bower_components/datatables/examples/server_side/jsonp.html (11695B)
DataTables example
DataTables server-side processing example with JSONP

Preamble

JSONP is a method of using JSON data from any server, regardless of XSS protection that modern browsers use. It is very useful for being able to retrieve JSON data from any domain name you choose and is easy to integrate with DataTables, thanks to jQuery's Ajax handler, as shown in this example.

Live example

Rendering engine Browser Platform(s) Engine version CSS grade
Loading data from server
Rendering engine Browser Platform(s) Engine version CSS grade

Initialisation code

$(document).ready(function() {
	$('#example').dataTable( {
		"bProcessing": true,
		"bServerSide": true,
		"sAjaxSource": "scripts/jsonp.php",
		"fnServerData": function( sUrl, aoData, fnCallback, oSettings ) {
			oSettings.jqXHR = $.ajax( {
				"url": sUrl,
				"data": aoData,
				"success": fnCallback,
				"dataType": "jsonp",
				"cache": false
			} );
		}
	} );
} );

Server response

The code below shows the latest JSON data that has been returned from the server in response to the Ajax request made by DataTables. This will update as further requests are made.


			
			
			

Other examples