Author |
Message |
Amy_Raye
Junior WebHelper
![Junior WebHelper Junior WebHelper](images/rank_1.gif)
![](images/avatars/gallery/artistic/LH_94.gif)
Joined: 20 Mar 2004
Posts: 3
Location: Pennsylvania
|
Posted:
Sat Mar 20, 2004 8:21 pm (20 years, 3 months ago) |
![Reply with Quote Reply with Quote](templates/4WebHelp2/images/lang_english/icon_quote.gif) ![Back to Top Back to Top](templates/4WebHelp2/images/icon_up.gif) |
Hey, when I run this script it tells me that I'm missing a ; in line 4 and an expected ( in 47/48. I don't know what this script wants, I've checked it over and all of the bits seem to be there. Any help would be great. (Also in the preview there seems to be a emoticon with sunglasses where there should be an 8. )
Code: | <html><head><title>amy</title>
<script language="JavaScript">
function valid(){
Var x;
x=document.datecount;
if (((x.month=01) || (x.month=03) || (x.month=05) || (x.month=07) || (x.month=08) || (x.month=10) || (x.month=12)) && ((x.day >= 1) || (x.day <=31)))
{
window.alert("Date Valid");
}
else
{
WINDOW.ALERT("INVALID DATE");
}
if ((x.month=02) && ((x.day >= 1) || (x.day <=29)))
{
window.alert("Date Valid");
}
else
{
WINDOW.ALERT("INVALID DATE");
}
if (((x.month=04)|| (x.month=06)|| (x.month=09)|| (x.month=11)) && ((x.day >= 1) || (x.day <=30)))
{
window.alert("Date Valid");
}
else
{
WINDOW.ALERT("INVALID DATE");
}
}
</SCRIPT>
</head>
<body>
<form name="datecount" method="post" action="">
<P>Insert a date here to find the days remaining in 2004:</P>
<P>Example: 01/01/2004
<input type="text" name="month">/
<input type="text" name="day">/2004
<input type="Submit" name="valid" value="valid" onclick="valid()">
</P>
</form></body></html> |
|
|
|
![Offline](templates/4WebHelp2/images/offline.gif) ![View User's Profile View User's Profile](templates/4WebHelp2/images/lang_english/icon_profile.gif) ![Find all posts by Amy_Raye Find all posts by Amy_Raye](templates/4WebHelp2/images/lang_english/icon_search.gif) ![Send Personal Message Send Personal Message](templates/4WebHelp2/images/lang_english/icon_pm.gif) ![AOL Instant Messenger AOL Instant Messenger](templates/4WebHelp2/images/lang_english/icon_aim.gif) |
![](images/spacer.gif) |
Darren
Team Member
![](images/rank_6.gif)
![](images/avatars/gallery/computers/apple.gif)
Joined: 05 Feb 2002
Posts: 549
Location: London
|
Posted:
Sun Mar 21, 2004 9:32 am (20 years, 3 months ago) |
![Reply with Quote Reply with Quote](templates/4WebHelp2/images/lang_english/icon_quote.gif) ![Back to Top Back to Top](templates/4WebHelp2/images/icon_up.gif) |
Well the smiley with the shades was because of the 8) which is the code for that particular smiley. You can get round that by putting code within the [code] tags, which I have done for you. |
|
|
![Offline](templates/4WebHelp2/images/offline.gif) ![View User's Profile View User's Profile](templates/4WebHelp2/images/lang_english/icon_profile.gif) ![Find all posts by Darren Find all posts by Darren](templates/4WebHelp2/images/lang_english/icon_search.gif) ![Send Personal Message Send Personal Message](templates/4WebHelp2/images/lang_english/icon_pm.gif) ![Visit Poster's Website Visit Poster's Website](templates/4WebHelp2/images/lang_english/icon_www.gif) |
![](images/spacer.gif) |
SfCommand
Senior WebHelper
![Senior WebHelper Senior WebHelper](images/rank_3.gif)
![](http://home.miguel.me.uk/pics/devil.png)
Joined: 10 Nov 2002
Posts: 143
Location: UK
|
Posted:
Sun Mar 21, 2004 6:42 pm (20 years, 3 months ago) |
![Reply with Quote Reply with Quote](templates/4WebHelp2/images/lang_english/icon_quote.gif) ![Back to Top Back to Top](templates/4WebHelp2/images/icon_up.gif) |
|
![Offline](templates/4WebHelp2/images/offline.gif) ![View User's Profile View User's Profile](templates/4WebHelp2/images/lang_english/icon_profile.gif) ![Find all posts by SfCommand Find all posts by SfCommand](templates/4WebHelp2/images/lang_english/icon_search.gif) ![Send Personal Message Send Personal Message](templates/4WebHelp2/images/lang_english/icon_pm.gif) ![Visit Poster's Website Visit Poster's Website](templates/4WebHelp2/images/lang_english/icon_www.gif) |
![](images/spacer.gif) |
Daniel
Team Member
![](images/rank_6.gif)
![](http://www.4webhelp.net/forums/images/daniel_avatar.php)
Joined: 06 Jan 2002
Posts: 2564
|
Posted:
Sun Mar 21, 2004 7:25 pm (20 years, 3 months ago) |
![Reply with Quote Reply with Quote](templates/4WebHelp2/images/lang_english/icon_quote.gif) ![Back to Top Back to Top](templates/4WebHelp2/images/icon_up.gif) |
Yes, it would, but
![Razz](/forums/images/smilies/icon_razz.gif) |
________________________________
![Image Image](http://www.4webhelp.net/images/daniel_sig.gif) |
|
![Offline](templates/4WebHelp2/images/offline.gif) ![View User's Profile View User's Profile](templates/4WebHelp2/images/lang_english/icon_profile.gif) ![Find all posts by Daniel Find all posts by Daniel](templates/4WebHelp2/images/lang_english/icon_search.gif) ![Send Personal Message Send Personal Message](templates/4WebHelp2/images/lang_english/icon_pm.gif) |
![](images/spacer.gif) |
Daniel
Team Member
![](images/rank_6.gif)
![](http://www.4webhelp.net/forums/images/daniel_avatar.php)
Joined: 06 Jan 2002
Posts: 2564
|
Posted:
Sun Mar 21, 2004 7:31 pm (20 years, 3 months ago) |
![Reply with Quote Reply with Quote](templates/4WebHelp2/images/lang_english/icon_quote.gif) ![Back to Top Back to Top](templates/4WebHelp2/images/icon_up.gif) |
Maybe the capital letter in "Var" is the problem. I changed that and my browser threw up some other errors, leading me to think that at least that problem had disappeared...
The errors were:
Quote: | Warning: 08 is not a legal ECMA-262 octal constant
Source File: http://www.4webhelp.net/test.php
Line: 117, Column: 78
Source Code:
if (((x.month=01) || (x.month=03) || (x.month=05) || (x.month=07) || (x.month=08) || (x.month=10) || (x.month=12)) && ((x.day >= 1) || (x.day <=31))) |
Quote: | Warning: 09 is not a legal ECMA-262 octal constant
Source File: http://www.4webhelp.net/test.php
Line: 135, Column: 44
Source Code:
if (((x.month=04)|| (x.month=06)|| (x.month=09)|| (x.month=11)) && ((x.day >= 1) || (x.day <=30))) |
|
________________________________
![Image Image](http://www.4webhelp.net/images/daniel_sig.gif) |
|
![Offline](templates/4WebHelp2/images/offline.gif) ![View User's Profile View User's Profile](templates/4WebHelp2/images/lang_english/icon_profile.gif) ![Find all posts by Daniel Find all posts by Daniel](templates/4WebHelp2/images/lang_english/icon_search.gif) ![Send Personal Message Send Personal Message](templates/4WebHelp2/images/lang_english/icon_pm.gif) |
![](images/spacer.gif) |
Amy_Raye
Junior WebHelper
![Junior WebHelper Junior WebHelper](images/rank_1.gif)
![](images/avatars/gallery/artistic/LH_94.gif)
Joined: 20 Mar 2004
Posts: 3
Location: Pennsylvania
|
Posted:
Sun Apr 18, 2004 5:21 am (20 years, 2 months ago) |
![Reply with Quote Reply with Quote](templates/4WebHelp2/images/lang_english/icon_quote.gif) ![Back to Top Back to Top](templates/4WebHelp2/images/icon_up.gif) |
Thanks for all the help, even with the silly emoticon! ![Wink](/forums/images/smilies/icon_wink.gif) |
|
|
![Offline](templates/4WebHelp2/images/offline.gif) ![View User's Profile View User's Profile](templates/4WebHelp2/images/lang_english/icon_profile.gif) ![Find all posts by Amy_Raye Find all posts by Amy_Raye](templates/4WebHelp2/images/lang_english/icon_search.gif) ![Send Personal Message Send Personal Message](templates/4WebHelp2/images/lang_english/icon_pm.gif) ![AOL Instant Messenger AOL Instant Messenger](templates/4WebHelp2/images/lang_english/icon_aim.gif) |
![](images/spacer.gif) |
Daniel
Team Member
![](images/rank_6.gif)
![](http://www.4webhelp.net/forums/images/daniel_avatar.php)
Joined: 06 Jan 2002
Posts: 2564
|
Posted:
Sun Apr 18, 2004 8:17 am (20 years, 2 months ago) |
![Reply with Quote Reply with Quote](templates/4WebHelp2/images/lang_english/icon_quote.gif) ![Back to Top Back to Top](templates/4WebHelp2/images/icon_up.gif) |
Was your problem solved? ![Smile](/forums/images/smilies/icon_smile.gif) |
________________________________
![Image Image](http://www.4webhelp.net/images/daniel_sig.gif) |
|
![Offline](templates/4WebHelp2/images/offline.gif) ![View User's Profile View User's Profile](templates/4WebHelp2/images/lang_english/icon_profile.gif) ![Find all posts by Daniel Find all posts by Daniel](templates/4WebHelp2/images/lang_english/icon_search.gif) ![Send Personal Message Send Personal Message](templates/4WebHelp2/images/lang_english/icon_pm.gif) |
![](images/spacer.gif) |
Amy_Raye
Junior WebHelper
![Junior WebHelper Junior WebHelper](images/rank_1.gif)
![](images/avatars/gallery/artistic/LH_94.gif)
Joined: 20 Mar 2004
Posts: 3
Location: Pennsylvania
|
Posted:
Mon May 03, 2004 1:44 am (20 years, 1 month ago) |
![Reply with Quote Reply with Quote](templates/4WebHelp2/images/lang_english/icon_quote.gif) ![Back to Top Back to Top](templates/4WebHelp2/images/icon_up.gif) |
Yes it was! Thanks again to everyone ![Very Happy](/forums/images/smilies/icon_biggrin.gif) |
|
|
![Offline](templates/4WebHelp2/images/offline.gif) ![View User's Profile View User's Profile](templates/4WebHelp2/images/lang_english/icon_profile.gif) ![Find all posts by Amy_Raye Find all posts by Amy_Raye](templates/4WebHelp2/images/lang_english/icon_search.gif) ![Send Personal Message Send Personal Message](templates/4WebHelp2/images/lang_english/icon_pm.gif) ![AOL Instant Messenger AOL Instant Messenger](templates/4WebHelp2/images/lang_english/icon_aim.gif) |
![](images/spacer.gif) |
|
Page generation time: 0.13194 seconds :: 18 queries executed :: All Times are GMT
Powered by
phpBB 2.0
© 2001, 2002 phpBB Group :: Based on an FI Theme