rem: console.log(d);  
context: Date.parseFormattedString = function (string) {  var regexp = "([0-9]{4})(-([0-9]{2})(-([0-9]{2})" +      "( ([0-9]{1,2}):([0-9]{2})? *(pm|am)" +      "?)?)?)?";  var d = string.match(new RegExp(regexp, "i"));  if (d==null) return Date.parse(string); // at least give javascript a crack at it.  var offset = 0;  var date = new Date(d[1], 0, 1);  if (d[3]) { date.setMonth(d[3] - 1); }  if (d[5]) { date.setDate(d[5]); }  if (d[7]) {    hours = parseInt(d[7]);    offset=0;    is_pm = (d[9].toLowerCase()=="pm")    if (is_pm && hours <= 11) hours+=12;    if (!is_pm && hours == 12) hours=0;    console.log(d);    date.setHours(hours);       }  if (d[8]) { date.setMinutes(d[8]); }  if (d[10]) { date.setSeconds(d[10]); }  if (d[12]) { date.setMilliseconds(Number("0." + d[12]) * 1000); }  if (d[14]) {      offset = (Number(d[16]) * 60) + Number(d[17]);      offset *= ((d[15] == '-') ? 1 : -1);  }  return date;}
meta: 9859	/local1/tlutelli/issta_data/temp/all_js/javascript/2007_temp/2007/9859/dad20eb6b8909c932893f6a619bc998496cb9e09/calendar_date_select_format_hyphen_ampm.js/buggy/public/javascripts/calendar_date_select_format_hyphen_ampm.js