I am working in JavaScript. I have date in below format:
Tue Sep 18 2012 01:30:00 GMT+0530 (India Standard Time)
I want to display it in below format
'Y-m-d h:i:s'
OR
How to get time only from (Tue Sep 18 2012 00:00:00 GMT+0530 (India Standard Time)) this format in JavaScript?
If you have a
Dateobject you can do this:If you have a
Stringjust do this before: