How do I convert DateTime format to ShortDateString in Jquery?
I h开发者_运维百科ave a date that I would like to convert to String format. /Date(1281067200000)/ is supposed to be 08/06/2010 12:00:00:00. How do I convert /Date(1281067200000)/ to 8/6/2010?
[UPDATED] Use dateJS:
SO thread
Edit: Try this: http://www.esqsoft.com/javascript_examples/date-to-epoch.htm
What type of string format? You could use yourDate.toString()
or yourDate.toLocaleDateString()
depending on your use case.
精彩评论