Home › Forums › JavaScript › Get the ID using javascript/jquery › Re: Get the ID using javascript/jquery
June 21, 2009 at 5:08 am
#59411
davesgonebananas
Member
Your process.php needs to take the id as input and generate the HTML for the information div.
Then your success() function needs to take a parameter that will contain the HTML outputted from process.php.
Code:
//div fades in when operation is a success
// data contains the html output of process.php
success: function(data){
// fade out, then replace the contents of the div then fade in
$(“#info_inner”).fadeOut(“fast”).html(data).fadeIn(“fast”);
}
// data contains the html output of process.php
success: function(data){
// fade out, then replace the contents of the div then fade in
$(“#info_inner”).fadeOut(“fast”).html(data).fadeIn(“fast”);
}