Skip to content

Event tracking on links with target=_top are broken #3187

@stag-enterprises

Description

@stag-enterprises

I've installed a self-hosted Umami on my website, in addition to using the provided script that adds event data attributes to all links elements.

Some links on my website are inside an iframe, and they include target=_top (or set by a <base target=_top>). This should cause these links to be opened in the top document (the tab itself), but when Umami event data attributes are added to it, the links open in the iframe.

Demo: https://stag.lol. Click “services”, and click any of the links. Even though a <base target=_top> is included in the iframe, the link opens inside the frame.

Database: PostgreSQL
Version: v2.15.1
Browser: Chrome 131
Deployment: Docker

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingfixed in devFixed in the dev branch

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions