webdev1
08-08-2003, 02:14 PM
Does anyone know if you can format a date in javascript. In cold fusion there is a fcn called DateFormat which is used in the following context: DateFormat(fieldname, 'yyyy-mm-dd'). Can you do anything like this w/js? I need to compare two dates and the dates must get entered in the form in the format of mm/dd/yyyy but js can't seem to tell between two years, it seems to only compare the months and days. I would like to be able to convert the format of the date to compare the two dates but don't know how to do that, or if it can even be done. Any help would be greatly appreciated! THANKS!