PDA

View Full Version : Help please! Calendar Script not passing input



rjbutterworth
03-25-2006, 02:27 AM
Loved the Calendar script - set it up and it seemed to work fine. I'm using CGIemail (with a text file resident on my server, so the form reads

<FORM name=test action=http://www.domainname.com/cgi-bin/cgiemail/calendar.txt method=post><script>DateInput('orderdate', true, 'DD-MON-YYYY')</script><INPUT type=image src="submit.gif" value="Send e-mail"></form>

It works - I get a success message and an email arrives fine... BUT! No matter what I set the sate to using the calendar, the date always comes through on the form as today's date. Doesn't matter what date you set (even though on the web page the selector appears to be working fine). I'm obviously missing something, so anyone's help would be really appreciated. Sorry to be a pleb :o

simonf
03-25-2006, 09:12 AM
Hi

Do you have a link to your form for us??

rjbutterworth
03-27-2006, 08:33 AM
Sorry Simonf - it's still in test and onffline - but, if it sheds any more light, a bit more detail:
* The form is a standrad form; action=post (cgiemail and working fine).
* An input from this calendar is being passed through cgiemail (just the default value, not the changed value).
* The calendar script is unmodified and on the page appears to be working fine.
* The code on the page (within the form) is as per the example code on the calendar download page http://www.dynamicdrive.com/dynamicindex7/jasoncalendar.htm:
------------------------------------------------------------
<script>DateInput('orderdate', true, 'DD-MON-YYYY')</script>
------------------------------------------------------------
with only one modification - the name of the input is changed in my form from 'orderdate' to 'arrivdate'.

Thinking about it, the problem seems to specifically be that, for some reason, my calendar is not updating the variable 'arrivdate' on changing value. The only value being passed, on posting the form, is the default calendar input value.

Hope this sheds some light - your help's much appreciated.

Richard.