logo       

[jQuery] inArray not working with dates: msg#02893

jQuery

Subject: [jQuery] inArray not working with dates


Can someone tell me what I may be doing wrong here?

var dateList = new Array();
dateList.push(new Date(2009,7-1,29));
dateList.push(new Date(2009,7-1,30));
dateList.push(new Date(2009,7-1,31));
var testdate = new Date(2009,7-1,30);
alert($.inArray(testdate,dateList)); //returns -1 ????

tia,

Dave

<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | Mail Home | sitemap | FAQ | advertise