jrotondo
09-12-2003, 10:13 AM
Hello,
I'm moving my sites from a previous host to my
new server, and I've run into a very confusing
problem. It seems that javascripts will only run if
they are embedded within the HTML page. If they
reference an external .js file, they don't run!
For instance, if I have <script>document.write(Date()+".")</script> within my
page, it works... but if I have that script as an
external file and then reference it like so...
<script language="javascript" src="date-script.js"></script>
...it doesn't work anymore! I know it's not my script
because it works just fine on the server I'm trying
to migrate from.
Does anyone have any bright ideas on this? I'm
stumped! Any help is greatly appreciated!
Thanks,
John
I'm moving my sites from a previous host to my
new server, and I've run into a very confusing
problem. It seems that javascripts will only run if
they are embedded within the HTML page. If they
reference an external .js file, they don't run!
For instance, if I have <script>document.write(Date()+".")</script> within my
page, it works... but if I have that script as an
external file and then reference it like so...
<script language="javascript" src="date-script.js"></script>
...it doesn't work anymore! I know it's not my script
because it works just fine on the server I'm trying
to migrate from.
Does anyone have any bright ideas on this? I'm
stumped! Any help is greatly appreciated!
Thanks,
John