Forum Moderators: open

Message Too Old, No Replies

Syntax Error - Dreamweaver

Syntax Error Line 2 Char 1

         

scout77

7:58 pm on Nov 5, 2004 (gmt 0)

10+ Year Member



Hi there, I'm building my first website with Dreamweaver Mx 7.0.1. The website is approx. 21 pages and all of the pages with the exception of the homepage(idex.html) have the same syntax error listed. I notice the error is located at the bottom left corner of the screen when you are in the iexplore browser view.

Line: 2
Char: 1
Error: Syntax Error
Code: 0

The code in one of the error pages is listed as follows:

<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">

Hoping someone can help.

Much appreciated,

Bernard Marx

8:22 pm on Nov 5, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



The line number will be referring to a script ¦ script block.
- not the entire HTML.
A <meta> tag won't be causing any script errors.

scout77

8:44 pm on Nov 5, 2004 (gmt 0)

10+ Year Member



Thanks for your help. I'm very new to this, how would I find the particular piece of javscript(I know to look in the code view, but not sure if the error will be hightlighted or not) and when I find it, what should I do? Sorry, I'm very new to this, but eager to learn.

scout77

2:54 pm on Nov 9, 2004 (gmt 0)

10+ Year Member



I've still been looking at how to fix the Syntax Error I am getting with the Javascript. Do you think that the setting I have on View/No Script Content/ has something to do with it?

Thanks,

DrDoc

10:09 pm on Nov 9, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Is there an error message in the script debugger/JavaScript console when you open the page in a browser?

scout77

4:08 pm on Nov 17, 2004 (gmt 0)

10+ Year Member



Hi DrDoc, yes an error pops up in the browser window so that everyone viewing the page can see a yellow triangle at the bottom left corner of the page. Any suggestions on how to fix this would be greately appreciated. I have this error on 19 of the 21 webpages in the site.

Bernard Marx

9:32 pm on Nov 17, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Any suggestions on how to fix this

I reckon paying a visit to a respectable Javascript forum, and then posting your code would seem to be the order of the day.

scout77

8:12 pm on Nov 18, 2004 (gmt 0)

10+ Year Member



Hi there BernardMarx, you mentioned that the syntax error may be because of a script block. Here is some of the Javascript code. Not sure how much of the code I should have put here, please tell me if I put too much, which section of the code would help.

Much appreciated,

Scout

<script language="JavaScript">
<!--
function mmLoadMenus() {
if (window.mm_menu_0817142409_0) return;
window.mm_menu_0817142409_0 = new Menu("root",82,18,"Arial, sans-serif",12,"#962D8B","#000000","#CCCCCC","#CCCCCC","left","middle",2,0,200,-5,7,true,true,true,0,true,true);
mm_menu_0817142409_0.addMenuItem("Structural","location='structural.html'");
mm_menu_0817142409_0.hideOnMouseOut=true;
mm_menu_0817142409_0.bgColor='#555555';
mm_menu_0817142409_0.menuBorder=1;
mm_menu_0817142409_0.menuLiteBgColor='#FFFFFF';
mm_menu_0817142409_0.menuBorderBgColor='#777777';


window.mm_menu_0817143724_0 = new Menu("root",163,16,"Arial, sans-serif",12,"#962D8B","#FF0000","#CCCCCC","#CCCCCC","left","middle",2,0,200,-5,7,true,true,true,0,false,true);
mm_menu_0817143724_0.addMenuItem("Structural&nbsp;/&nbsp;Architectural","location='structural.html'");
mm_menu_0817143724_0.addMenuItem("Mechanical","location='mechanical.html'");
mm_menu_0817143724_0.addMenuItem("Electrical&nbsp;/&nbsp;Instrumentation","location='electrical.html'");
mm_menu_0817143724_0.addMenuItem("Civil","location='civil.html'");
mm_menu_0817143724_0.addMenuItem("Project&nbsp;Services","location='pservices.html'");
mm_menu_0817143724_0.addMenuItem("Processing","location='processing.html'");
mm_menu_0817143724_0.hideOnMouseOut=true;
mm_menu_0817143724_0.bgColor='#555555';
mm_menu_0817143724_0.menuBorder=1;
mm_menu_0817143724_0.menuLiteBgColor='#FFFFFF';
mm_menu_0817143724_0.menuBorderBgColor='#777777';
window.mm_menu_0817134609_0 = new Menu("root",52,16,"Arial, sans-serif",12,"#962D8B","#FF0000","#CCCCCC","#CCCCCC","left","middle",2,0,200,-5,7,true,true,true,0,false,true);
mm_menu_0817134609_0.addMenuItem("Careers","location='career.html'");
mm_menu_0817134609_0.hideOnMouseOut=true;
mm_menu_0817134609_0.bgColor='#555555';
mm_menu_0817134609_0.menuBorder=1;
mm_menu_0817134609_0.menuLiteBgColor='#FFFFFF';
mm_menu_0817134609_0.menuBorderBgColor='#777777';
window.mm_menu_1025115516_0 = new Menu("root",87,18,"Arial, sans-serif",12,"#962D8B","#FF0000","#CCCCCC","#CCCCCC","left","middle",3,0,200,-5,7,true,true,true,0,false,true);
mm_menu_1025115516_0.addMenuItem("Commitment","location='aboutus2.html'");
mm_menu_1025115516_0.hideOnMouseOut=true;
mm_menu_1025115516_0.bgColor='#555555';
mm_menu_1025115516_0.menuBorder=1;
mm_menu_1025115516_0.menuLiteBgColor='#FFFFFF';
mm_menu_1025115516_0.menuBorderBgColor='#777777';

mm_menu_1025115516_0.writeMenus();
} // mmLoadMenus()
//-->
</script>