...

View Full Version : runtime error - simple javascript detection and redirect



dcale
06-02-2003, 06:47 PM
I have a user who is getting a javascript error. Here is the script I'm running to detect whether or not the user has javascript turned on, then to redirect as necessary.



<script language=javascript1.1>
<!-- Hide Script
window.location="pdwebmain.htm")
//End Hide Script-->
</script>

I think I know what the problem is, but am not sure how to fix it. There is a ")" following the pdwebmain.htm reference. Shouldn't there be a preceding "(" somewhere in the script???? If so, where should it be located within the script.

However, the error message that appears is:
Error: expected ';'

Can anyone tell me what is wrong with this script?

Any help appreciated.

Thanks!
Dave

Mr J
06-02-2003, 06:53 PM
The bracket ) should not be there just delete it and all should be well

dcale
06-02-2003, 06:55 PM
Thank you for the quick response. I will remove the ")" and see how that works.

Thanks again folks!
Dave



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum