Question

I can't find out what the problem is, and why I keep receiving this error in Internet Explorer 8, as it's the only error that I am receiving. Any thoughts as to what it means, or a simple solution? I haven't noticed any problems with my code though, it's just the message that bugs me.

Webpage error details.

User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729) Timestamp: Mon, 7 Sep 2009 19:11:13 UTC

Message: HTML Parsing Error: Unable to modify the parent container element before the child element is closed (KB927917)
Line: 0
Char: 0
Code: 0
Was it helpful?

Solution

The answer is there in the error - KB927917 says:

This problem occurs because a child container HTML element contains script that tries to modify the parent container element of the child container. The script tries to modify the parent container element by using either the innerHTML method or the appendChild method.

For example, this problem may occur if a DIV element is a child container in a BODY element, and a SCRIPT block in the DIV element tries to modify the BODY element that is a parent container for the DIV element.

OTHER TIPS

The error message you are getting indicates "KB927917". This is a reference to an entry in Microsoft's knowledge base.

More specifically : Why do I receive an "Operation aborted" error message when I visit a Web page in Internet Explorer?

On that page, there are informations for both end-users and developpers ; those might help you understand what is causing this problem.
This part seems interesting (quoting) :

This problem occurs because a child container HTML element contains script that tries to modify the parent container element of the child container. The script tries to modify the parent container element by using either the innerHTML method or the appendChild method.

For example, this problem may occur if a DIV element is a child container in a BODY element, and a SCRIPT block in the DIV element tries to modify the BODY element that is a parent container for the DIV element.


There is also a link to this blog entry : What Happened to Operation Aborted?

On that entry, there is exactly the message you are getting (which seems to be the way IE8 deals with that problem -- where older versions were just displaying some kind of alert box and a blank page) ; so, might you too ;-)

This workaround works fine:

setTimeout( function() {
    "scary DOM manipulations"
}, 0 );
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top