Skip to content Skip to sidebar Skip to footer

Jquery Ajax Request Echo Html Data

I'm making an ajax request to my PHP script which will echo out a certain # of tables ( different each time), that I want to include on my original page when a user clicks the subm

Solution 1:

For example you could make an ajax request and fill the div with it

 $.get("draw_tables.php", function(data) {
 $("#table_layout").html(data);
 });

This will fill your table_layout id with the data from the ajax request.

Solution 2:

$('#table_layout').append(data);

Solution 3:

Inside the success callback you should add:

$('#table_layout').append(data);

Post a Comment for "Jquery Ajax Request Echo Html Data"