I made an ajax call to search for entries. After the result is obtained from ajax, when I try to click on it, the page will move up.
My function to call ajax:
function ajax_search_primarycare(keyword, userId){
if(keyword.length >= 3){
var pricareId = jQuery('#primarycare_provider_id').val();
var pricareName = jQuery('#primarycare_provider_name').val();
var pricareStatus = jQuery('#primarycare_icon_status').val();
var primary_badge_status = jQuery('#primary_badge_status').val();
$.ajax({type: "POST",
url: "ajax_search_primarycareprovider.php?keyword="+keyword+"&userId="+userId+"&pricareId="+pricareId+"&pricareName="+pricareName+"&pricareStatus="+pricareStatus+"&primary_badge_status="+primary_badge_status,
success: function(msg){
$("#sect_primarycare").html(msg);
}
});
return false;
}
I added return false after calling ajax, but still no result.
Thanks in advance
source
share