Apologies if this is a stupid question as Im completly new to JAvascript and web programming!
I'm currently using Dreamweaver to do some test scripts and the internal JS editor is highlighting a syntax error with my script. The only problem is that there is no indication as to what the error is or what I might need to do to fix it!
When I paste this code directly into the web page, the script seems to work without issue!
My script is as follows (saved in an external .js file):
1 // JavaScript Document
2 <script type="text/javascript">
3
4 function coloralternatetablerows(id)
5 {
6 // If the tag exists within the document
7 if(document.getElementsByTagName)
8 {
9 // rest of the script ommitted for clarity
10 }
11 }
The synax error is highlighted as line 7.
Can anyone help me figure this out?!
More importantly... can anyone direct me to a good resource to help me with this sort of issue in the future?