开发者

Chrome: Uncaught Error: can't load XRegExp twice in the same frame

The following code will fail in both of my chromes on 2 different computers (Windows 7 both of them, Chrome 12.0.742.100).

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
    <head>
        <title>Test</title>
        <script type="text/javascript">
            location.hash = "#one";
            location.hash = "#two";
            location.hash = "#three";
        </script>
    </head>
    <body>
        This will error out "Uncaught Error: can't load XRegExp twice in the same frame" in chrome. Anyone got an answer?
    </body>
</html>

I feel like I tried everything. Can anyone confirm this error on chrome, and does anyone have an idea as to how I fix it? Thanks a lot.

URL to error: http://jalsoedesign.net/开发者_如何学运维test/hashchanging/

I should add: It works fine, does what it should (changes the page hashes), but still comes out with an error.


It works fine with me on Chrome 12.0.742.100 on Win7. I'm assuming you have installed extensions? disable all extensions (or go to incognito mode) and try to load your page again. Errors from content scripts are also displayed in the javascript console. If you are not using XRegExp on your page, probably one of the extensions does.

Edit:

The source of the exception should be located to the right. Click it to go to the script that caused the exception.


Extensions that use XRegExp should upgrade to v2.0.0 or later. That will avoid this error even when XRegExp is (inappropriately) loaded more than once in the same frame.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜