This is my code: In A Function:
var daaa=document.getElementById('da').value= year+ "-" +month+ "-" +day;
document.form1.bookingsession.focus();
var coords = {
"lat": daaa
};
$.get('bs.php', coords, function () {
alert('data sent');
});
and my php code is:
<?php
$output = isset($_GET['lat']) ? $_GET['lat'] : 0;
print("$output");
?>
And when i print $output i get the value as 0, but actually have to get the value which is on tha variable daaa. Let me know where i made mistake.... Thank you in advance
$.get('bs.php', { lat: 50 });
- what does the request return? – Matt Stone Mar 20 at 10:27