I am trying to dynamically change the select statement that populates my jqGrid.
I have used ajax to send values to the php file that a user selects from a dropdown list
However on var_dump I get the value as null.
My ajax code is as follows:
function dropDownChange(){
var e = document.getElementById(“dateValue”);
var dateValue= e.options[e.selectedIndex].value;
var data =”popup=true&” +”dateValue=”+dateValue;
console.log(data);
$.ajax({
type: ‘GET’,
data: data,
contentType: ‘application/json’,
url: “detail2k12DhavalMonday.php”,
data : data,
success : function(data,status) {
console.log(status);
$(“#griddef”).html( data );
},
error : function(data,status){
console.log(status);
// console.log(“no”);
}
});
}
console.log(data) shows the right values.
I am trying to access the values as
$_GET[‘dateValue’];
I have also tried
jqGridUtils::GetParam(‘dateValue’);
But I am still getting NULL when I var_dump the variable!!
Copyright 2014 TriRand LtdAll Rights ReservedRSS
Back to Top