Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

IE6 - Line: 2 Char: 1 Error: Syntax error Code: 0

Status
Not open for further replies.

shogo2040

Programmer
Joined
Mar 2, 2006
Messages
1
Location
US
THE BLASTSED CODE 0 ERROR.

IE6 - Line: 2 Char: 1 Error: Syntax error Code: 0

I've read about this in other forums, with no solutions. What I've done is override another function defined in an external .js file (3rd party).

Even though I have an error in IE6, the script still works fine and completes fine. In addition, the debugger built in to firefox says there are no errors or warnings whatsoever.

My script works fine in all browsers, but have that yellow exclamation mark on the bottom left of the IE6 browser just looks bad.

1. What the heck does Code: 0 mean?
2. What is the proper syntax to override an existing function from an external .js file? I tried both formats:

function myfunc(param1, param2)

or

myfunc = function(param1, param2)

ps: remember, my function actually is working fine in ie6, so as for why ie6 is barfing Code 0 is beyond me!
 
It's telling you that there is a syntax error. The extra information about line number etc is totally misleading and (in this case) is of no value to you.

Without looking at the page that calls the code, and the external js code file - and your override code for that function in the code file... we can't really go much further on this.

Cheers,
Jeff

[tt]Jeff's Page @ Code Couch
[/tt]

What is Javascript? FAQ216-6094
 
I believe this means that you're trying to include a script file that cannot be found.

Make sure you are including it correctly, with the correct pathname, and filename... and make sure the case of both of those is correct. Some hosts run on case-sensitive operating systems where this:

Code:
src="scripts\someFile.js"

is totally different from this:

Code:
src="Scripts\someFile.js"

or this:

Code:
src="Scripts\somefile.js"

Hope this helps,
Dan

[tt]Dan's Page [blue]@[/blue] Code Couch
[/tt]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top