I want to convert "04/09/2013" to date so I can compare start date and end date like, if (stardate < enddate) { //do this } else {}. I want to convert it to MM/DD/YYYY format.
What have you tried? There is a thousand of almost exactly similar questions here. And you didn't even specify whether you want dd/mm/yyyy or mm/dd/yyyy format.
dd/mm/yyyyormm/dd/yyyyformat.var d = new Date("04/09/2013");Watch out for UTC vs. Local time though. This might end up being April 9th or September 4th.