L
Laphan
Hi All
Have a couple of quandaries that I was wondering if you could assist on:
1) Created a page whereby the user selects the day, month and year from 3
separate pop-ups rather than all the rigmarole of checking what kind of date
they enter in 1 text box. My quandary here is that there is going to be a
smart alec (probably a brown noser who wants to take my client away from me)
who'll select something like 31 April 2003 from the pop-ups, which will
obviously make the system blow a gasket as it tries to file this incorrect
date.
Has anybody thought of a good way to trap this without a load of JavaScript
whatsits?
I was thinking of checking the month and if the day was over 30 for month
x,y,z then fix it to 30 before I file it to the DB. Best way?
2) I have setup a system where news messages are given an expiry date so
that when they are older than today's date they aren't displayed on the
site.
My problem is that even though I thought my syntax of:
IF MyDateVar < Now() THEN
don't display it
ELSE
display
END IF
was OK, if MyDateVar is the same date as Now() it's still classing it as
expired even though my test clearly shows that it is testing if it is less
than today (ie, Now).
Bizarre or what??
If you are kind enough to reply, could you please post in the NG rather than
my email address, as I have 'fudged' it to stop bogus MS viruses.
Rgds
Laphan
Have a couple of quandaries that I was wondering if you could assist on:
1) Created a page whereby the user selects the day, month and year from 3
separate pop-ups rather than all the rigmarole of checking what kind of date
they enter in 1 text box. My quandary here is that there is going to be a
smart alec (probably a brown noser who wants to take my client away from me)
who'll select something like 31 April 2003 from the pop-ups, which will
obviously make the system blow a gasket as it tries to file this incorrect
date.
Has anybody thought of a good way to trap this without a load of JavaScript
whatsits?
I was thinking of checking the month and if the day was over 30 for month
x,y,z then fix it to 30 before I file it to the DB. Best way?
2) I have setup a system where news messages are given an expiry date so
that when they are older than today's date they aren't displayed on the
site.
My problem is that even though I thought my syntax of:
IF MyDateVar < Now() THEN
don't display it
ELSE
display
END IF
was OK, if MyDateVar is the same date as Now() it's still classing it as
expired even though my test clearly shows that it is testing if it is less
than today (ie, Now).
Bizarre or what??
If you are kind enough to reply, could you please post in the NG rather than
my email address, as I have 'fudged' it to stop bogus MS viruses.
Rgds
Laphan