Solved

How do I convert dd-mmm-yyyy (14-Sep-2004) into javascript date format?

Posted on 2004-09-14
3
1,268 Views
Last Modified: 2012-05-05
How do I convert dd-mmm-yyyy (14-Sep-2004) into javascript date format?

I'd also like to be able to deal with the following kind of date string 1-Sep-2004 (where we unfortunately encounter d-mmm-yyyy rather than the desired dd-mmm-yyyy.
0
Comment
Question by:GessWurker
  • 2
3 Comments
 
LVL 9

Accepted Solution

by:
cwolves earned 500 total points
ID: 12057662
new Date('14-sep-2004'.replace('-', ' '));

in other words, use spaces instead of dashes
0
 

Author Comment

by:GessWurker
ID: 12057710
Perfect! Thanks!
0
 
LVL 9

Expert Comment

by:cwolves
ID: 12057725
yep :-)  and ty
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
JS Plugin Chaining 2 32
Check if Object property exists? 3 19
Apply tab index in forms 6 36
More SharePoint App with Angular and Bootstrap 17 18
Today I would like to talk about localizing (Internationalization) JavaScript applications. Introduction When creating an application that is going to be used by many people around the globe, it is important to remember that not everyone speak…
The task A number given should be formatted for easy reading by separating digits into triads. Format must be made inline via JavaScript, i.e., frameworks / functions are not welcome. So let’s take a number like this “12345678.91¿ and format i…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

867 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now