My ajax function:
function get_employee_list(Parameter){
$.ajax({
url: 'resource/php/search_profile.php',
type: 'POST',
data: { var1 : Parameter},
async: false,
success: function (response) {
alert(response);
},
cache: false,
contentType: false,
processData: false
});return false;
}
My search_profile.php file:
<?php
echo $_POST['var1'];
?>
The response string says var1 is undefined variable. Is there anything wrong in my ajax syntax?