Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow script elements to use attribution #447

Merged
merged 2 commits into from
May 27, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions EVENT.md
Original file line number Diff line number Diff line change
Expand Up @@ -135,13 +135,16 @@ window.open(
```

`event` sources do not require any user interaction and can be registered via
`<img>` tags with the new `attributionsrc` attribute:
`<img>` or `<script>` tags with the new `attributionsrc` attribute:
```html
<img src="https://advertiser.example/pixel"
attributionsrc="https://adtech.example/attribution_source?my_ad_id=123">

<script src="https://advertiser.example/register-view"
attributionsrc="https://adtech.example/attribution_source?my_ad_id=123">
```

Specifying a URL value for `attributionsrc` within `<a>`, `<img>`, or
Specifying a URL value for `attributionsrc` within `<a>`, `<img>`, `<script>` or
`window.open` will cause the browser to initiate a separate `keepalive` fetch
request which includes the `Attribution-Reporting-Eligible` request header.

Expand Down