Can someone provide me with a regex for the following? (Using Javascript)
source string: Jan 2 2010 6:00PM
I want the resulting string to show only the time, as shown below. (example above used)
result string: 6:00 PM
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Replace
(\d{1,2}:\d{1,2})([AP]M)with\1 \2Update: Use
\d{2}instead of\d{1,2}if the source string is guaranteed to be in theHH:MMformat.