Home Articles FAQs XREF Games Software Instant Books BBS About FOLDOC RFCs Feedback Sitemap
irt.Org

Feedback on: irt.org FAQ Knowledge Base Q1, January 07, 2000 at 09:26:24:

You are here: irt.org | About | Feedback | 704 [ previous next ]

Feedback on:
irt.org FAQ Knowledge Base Q1

Sent by
Mike Hughes-Chamberlain on January 07, 2000 at 09:26:24:

Worth:
Worth reading

Length:
Just right

Technical:
Just right

Comments:
I don't think this technique actually works - at any rate, not on my PC (using IE5 under NT4) - it does not seem to observe the correct number of days in each month. For example, 31/4/1957 is considered valid (whereas 31/4 does cause an error). Similarly, 29/2/nnnn works OK for any year, not just leap years.

(For testing, I simplified the isDate function as follows, but I don't think this will have made any difference.)

function isDate (day,month,year) {
var test = new Date(year,month,day);
if (day == 0) return false;
if (month == 0) return false;
if (year == 0) return false;
if ((year == test.getFullYear()) &&
(month == test.getMonth()) &&
(day == test.getDate()))
return true
else
return false
}





Other feedback on 'irt.org FAQ Knowledge Base Q1' - show all

©2018 Martin Webb