I am sending data from jquery to php using ajax but the problem is that whenever i send Boolean data through jquery php recieved it as a string. but i want Boolean data as Boolean not as a string
this is the code
$.ajax({
type: "POST",
url: "updaterecord.php",
data: { id:i, table:t, field:f, data: d },
dataType: "json",
success:function(s){
alert("Saved Successfully ");
},
error:function(e){
alert("Error ");
}
});
now if i send true on php side i get true as a string not as a Boolean value.is there any way to send Boolean data as Boolean