D
Doug Stewart
I have some javascript that I would like to put into an external file, that
is referenced by my page. I've seen multiple explanations of how to do this.
Three examples:
<script language="javascript" type="text/javascript" src="xxx.js"></script>
<SCRIPT SRC="xxx.js" LANGUAGE="JavaScript"></SCRIPT>
<script src="xxx.js"></script>
What is the correct format? I've heard that if one uses the incorrect
format, that it might work in some browsers but not in others. As I can't
test all browsers, I'm hoping for advice on the correct way of doing this.
Do I just take the javascript currently in my page and stick it in a file,
or do I need to strip out the start and end? Again, the information I've seen
on this is not consistent.
Many thanks for any guidance.
Doug Stewart
is referenced by my page. I've seen multiple explanations of how to do this.
Three examples:
<script language="javascript" type="text/javascript" src="xxx.js"></script>
<SCRIPT SRC="xxx.js" LANGUAGE="JavaScript"></SCRIPT>
<script src="xxx.js"></script>
What is the correct format? I've heard that if one uses the incorrect
format, that it might work in some browsers but not in others. As I can't
test all browsers, I'm hoping for advice on the correct way of doing this.
Do I just take the javascript currently in my page and stick it in a file,
or do I need to strip out the start and end? Again, the information I've seen
on this is not consistent.
Many thanks for any guidance.
Doug Stewart