I create to file ajax.php
and jajaxget.php
.
script in ajax.php is-
<script>
var data={name:"nikhil"};
$.ajax({type:"post",url:"jajaxget.php",data: {name:"nikhil"},success:function(r,s){alert(s);alert(r);}});
</script>
and jajaxget.php is
<!doctype html>
<html>
<body>
<?php
echo $_POST["name"];
?>
ajax.php works fine and in alert i can see the data which i send. I get a success alert and this ALERT
But when i open the get.php file in browser there is nothing . "nikhil" should show on the page. but the page is blank . why data is not recived by jajaxget.php
file. It may be very foolish question .but please help