Skip to content

Firefox: Can't leave step after loading external web page in a step #299

@breity

Description

@breity

To reproduce, create a project with a step that has a link to another page outside of WISE (and the link target is the current page) plus another step or two. View the project, open the step, and click on the link. Then try to visit any other step in the project. Firefox will prevent navigation and you'll see these errors:

Error: Permission denied to access property 'nodeId'
http://wise.berkeley.edu/vlewrapper/vle/view/vle/vleview_core.js
Line 963

Error: Permission denied to access property 'document'
http://wise.berkeley.edu/vlewrapper/vle/view/vle/vleview_core.js
Line 879

In Chrome, you will be able to navigate to another step, but will see this security warning at the same locations in vleview_core.js:

Uncaught SecurityError: Blocked a frame with origin "http://outside.url" from accessing a frame with origin "http://outside.url". Protocols, domains, and ports must match.

The problem is that the document element for the step content iframe has been set to an external site, so WISE does not have access to the iframe document anymore.

We don't have this problem with outside URL steps because we generate another iframe to load the external page. We should think about the best way to deal with this. Maybe add "target='_blank'" to all links in step content? Something else?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions