Forum Moderators: open

Message Too Old, No Replies

'Done, but with errors on page' message in IE

Error message in IE makes no sense

         

rootmeista

11:30 pm on Feb 17, 2005 (gmt 0)

10+ Year Member



I am building a website for a client using html, css, php and mysql.

When testing in IE version 6 on Win XP, there appears a little yellow icon in the lower left corner that says: 'Done, but with errors on page'.

The page shows up correct, but it is still annoying that error messages come up. The details tell me the problem is on Line 1, Char 1, Error: Object required, Code: 0, Url:theurltopage

After commenting out sections on different pages, IE renders them ok, but the code that was removed contains absolutely no errors. It is a big mystery.

Is there a way to figure out what the error actually might be? Or is this another of IE's little glitches?

tedster

11:42 pm on Feb 17, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Hello rootmeista, and welcome to the forums.

This is a script error massage (usually javascript) - and not an HTML error. Line 1 Character 1 of whatever script is on the page is the spot to look, rather than Line 1 Character 1 of the HTML.

zollerwagner

11:50 pm on Feb 17, 2005 (gmt 0)

10+ Year Member



You might try loading the page in Opera or Firefox. They have JavaScript consoles that will give you more help in figuring out what's wrong.

rootmeista

1:12 am on Feb 18, 2005 (gmt 0)

10+ Year Member



Thanks guys for swift reply.

I've tried your suggestions to no avail. Opera and FF javascript console shows no errors or messages.

I've tried to remove the little javascript there is, and the references to the javascript function, but this does not remove the error either.

What is the chance that the problem is not Javascript related? Could a link to the page help identify the issue?

rocknbil

1:32 am on Feb 18, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



You cannot find this

theurltopage

Anywhere in the source code of the page or any files linking to it?

If you set IE to "always dispay notification about script errors" in Internet Options it will actually pop up the error for you.

zollerwagner

3:20 am on Feb 18, 2005 (gmt 0)

10+ Year Member



Do you have any javascript links on the page? Maybe something like this:


<a href="javascript:history.go(-1);" title="go back">last page visited</a>

rootmeista

7:58 am on Feb 18, 2005 (gmt 0)

10+ Year Member



Yes, I have some javascript lines that makes a popup

For the link I have:
<a href="popups/forgot_password.php" onClick="popwin('popups/forgot_password.php'); return false;">Forgot your password?</a>

The function itself is like this:
<script language="JavaScript" type="text/JavaScript">
<!--
var newwindow;
function popwin(url){newwindow=window.open(url,'name','height=500,width=620, toolbar=yes, menubar=no, location=no, directories=no, status=yes');
if (window.focus) {newwindow.focus()}
}
//-->
</script>

But it does not seem to help to remove this code.

The pages are build up with various php files that gets included with the php include() function. If I take the source code from 'view source' and load that up as a html or php file, IE does not generate an error. But all that is server side, and from my understanding should not generate any browser errors.

I've included a stripped down version (excluding links, urls, DB etc) at

<Sorry, no personal URLs.
See Terms of Service [webmasterworld.com]>

The mysql error at the bottom does not have anything to do with the IE error. I've left the javascript in there.

Refreshing the page usually makes the error message go away.

I am out of ideas, and would very much like to see what is causing this behaviour in IE.

[edited by: tedster at 8:20 am (utc) on Feb. 18, 2005]

zollerwagner

8:19 am on Feb 18, 2005 (gmt 0)

10+ Year Member



[The mods are going to ask you to remove your link...or do it for you. Yep, that's terribly disfunctional in my mind, too. It makes it much harder to examine code. I think they're worried that we're promoting our web sites.]

Hmm. Try validating it with the w3c.org html/xhtml validator. You've got something like 38 warnings in there that could be related. It's always a good idea to clean up those things first. A lot of those probably came about when you cleaned out the content, but some resulted from not switching over to XHTML (you're still writing HTML code).

You'll want to validate the style sheet, too.

In the version you posted, I don't see any code error messages in my ie6.0. Did you?

You can't use IE to save your page because it tends to change things, especially the style sheets. I think you'll find one of the other browsers better for that.

BTW, there's a good little extension for Firefox that tests your HTML validation on the fly using code stored on your own computer. It's called "HTML Validator (based on Tidy)" It's very useful. You can google on the extension's name (or send me a message through the forum) me for a link.

PCInk

10:07 am on Feb 18, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Firefox and Netscape dont seem to always inform of errors in JavaScript.

However, load the page and type JavaScript: into the address bar (with the colon) and this should show errors for you.

Sometimes JavaScript errors appear only in one browser, so this may not work, but is worth a try.