Can anyone tell me how to convert the date format to string format in JavaScript Remoting?
Below is my code
@RemoteAction
global static theHRMS__Employee__c getEmployee() {
Contact c=[select birthdate__c from contact where id=0039000001CoN3m];
return c;
}
My VFP:
Visualforce.remoting.Manager.invokeAction(
'{!$RemoteAction.NewUIEmployeeContr.getEmployee}',
function(result, event){
if (event.status) {
Var bdate=result.birthdate__c ;
alert(bdate);
}
The above code gives alert message like
731808000000
But my actual birthdate is 22/11/1992
I dono how to convert the date to string ?
alert(new Date(bdate));