javascript - convert date from 23-08-2015 00:00:00 to Tue Aug 23 2015 00:00:00 GMT+0530 -


i have date in 23-08-2015 00:00:00 format in controller , pass view using viewdata. want convert date tue aug 23 2015 00:00:00 gmt+0530 format.. possible controller or can convert in view using jquery?

can me solve this?

in javascript, if create new date object string have, you'll desired format.

var testdate = new date("23-08-2015 00:00:00"); console.log(testdate); 

output:

tue nov 08 2016 00:00:00 gmt+0530 (india standard time) 

Comments

Popular posts from this blog

java - UnknownEntityTypeException: Unable to locate persister (Hibernate 5.0) -

python - ValueError: empty vocabulary; perhaps the documents only contain stop words -

ubuntu - collect2: fatal error: ld terminated with signal 9 [Killed] -