i have 3 text field with jquery calender plugin working... the issue I am facing is that in the very first field of input the date pass the ajax function and returns the value from data base via php but the second and the third fields doesn't passes their values to ajax so I am not receiving the value.
the Ajax code is given below
$('.submit-button').on('click',function(){
var name = $('input#popupDatepicker').val();
var id = $(this).attr('id').split('_')[1];
if ($.trim(name,id)!=''){
$.post('pages/name.php',{name:name,id:id},function(data){
$('div#name-data').html(data);
document.getElementById("#name-data").innerHTML =(data);
});
}
});
The Html code
> input type="text" class="datecontrol" id="popupDatepicker"
this is the input field and it is replicated in while loop as im getting data from database