php - Passing post value with ajax -
i have code in index.php:
$('#whois').click(function () { //console.log("button clicked"); $('#whois_content').html(""); $('#fade').fadeout('slow', function () { urllinkas(); }); });
i want pass post value test.php inside script, so:
$('#whois').click(function () { //console.log("button clicked"); $.ajax({ type: "post", url: "test.php", data: info, success: function(){ //dont know write here } $('#whois_content').html(""); $('#fade').fadeout('slow', function () { urllinkas(); }); });
and call post value in test.php $_post['info']
maybe understand im saying.
this better
$.post("test.php", { info: "something", moreinfo: "something else" }) .done(function(data) { $('#whois_content').html(""); $('#fade').fadeout('slow', function () { urllinkas(); }); });
Comments
Post a Comment