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

Add referral tags to home & account product links #14478

Merged
merged 2 commits into from
Apr 29, 2024
Merged
Show file tree
Hide file tree
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
20 changes: 4 additions & 16 deletions bedrock/mozorg/templates/mozorg/account.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
{% extends "base-protocol-mozilla.html" %}

{% set _entrypoint = 'mozilla.org-firefox-accounts' %}
{% set referrals = '?utm_source=www.mozilla.org&utm_medium=referral&utm_campaign=account' %}
Comment on lines 11 to +12
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Usually the utm_tags use _entrypoint values, but here the location is no longer valid (/firefox/accounts moved to /accounts) so I'm using params independent on it.

At the same time I'm not updating the _entrypoint value so the data collected stays consistent even when it doesn't reflect the right location today.


{% block page_title %}{{ ftl('mozilla-accounts-get-a-mozilla-account', fallback='firefox-accounts-get-a-firefox-account') }}{% endblock %}

Expand Down Expand Up @@ -81,26 +82,15 @@ <h2>{{ ftl('mozilla-account-sign-in-to', fallback='firefox-accounts-sign-in-to')
{% endif %}
</ul>

<a href="https://monitor.mozilla.org/">
{% set mozilla_monitor = switch('mozilla-monitor-brand-name') %}
<h4 class="mzp-c-wordmark mzp-t-wordmark-sm {% if mozilla_monitor %}t-product-mozilla-monitor{% else %}mzp-t-product-monitor{% endif %}">
{% if mozilla_monitor %}
{{ ftl('firefox-accounts-mozilla-monitor', fallback='firefox-accounts-firefox-monitor') }}
{% else %}
{{ ftl('firefox-accounts-firefox-monitor') }}
{% endif %}
</h4>
</a>
<a href="https://monitor.mozilla.org/{{ referrals }}" rel="external noopener"><h4 class="mzp-c-wordmark mzp-t-wordmark-sm t-product-mozilla-monitor">{{ ftl('firefox-accounts-mozilla-monitor', fallback='firefox-accounts-firefox-monitor') }}</h4></a>
<ul class="mzp-u-list-styled">
<li>{% if LANG == 'en-US' %}Get automated removal of your exposed info from sites that are selling it{% else %}{{ ftl('firefox-accounts-get-email-alerts') }}{% endif %}</li>
</ul>

{% if ftl_has_messages('firefox-accounts-protect-your-identity') %}
<a href="https://relay.firefox.com/"> <h4 class="mzp-c-wordmark mzp-t-wordmark-sm mzp-t-product-relay">{{ ftl('firefox-accounts-firefox-relay') }}</h4></a>
<a href="https://relay.firefox.com/{{ referrals }}" rel="external noopener"><h4 class="mzp-c-wordmark mzp-t-wordmark-sm mzp-t-product-relay">{{ ftl('firefox-accounts-firefox-relay') }}</h4></a>
janbrasna marked this conversation as resolved.
Show resolved Hide resolved
<ul class="mzp-u-list-styled">
<li>{{ ftl('firefox-accounts-protect-your-identity') }}</li>
</ul>
{% endif %}

<a href="{{ url('products.vpn.landing') }}"><h4 class="mzp-c-wordmark mzp-t-wordmark-sm mzp-t-product-vpn">{{ ftl('firefox-accounts-mozilla-vpn') }}</h4></a>
<ul class="mzp-u-list-styled">
Expand All @@ -112,13 +102,11 @@ <h4 class="mzp-c-wordmark mzp-t-wordmark-sm {% if mozilla_monitor %}t-product-mo
{% endif %}
</ul>

<a href="https://getpocket.com/"><h4 class="mzp-c-wordmark mzp-t-wordmark-sm mzp-t-product-pocket">{{ ftl('firefox-accounts-pocket') }}</h4></a>
{% if ftl_has_messages('firefox-accounts-protect-your-identity') %}
<a href="https://getpocket.com/{{ referrals }}" rel="external noopener"><h4 class="mzp-c-wordmark mzp-t-wordmark-sm mzp-t-product-pocket">{{ ftl('firefox-accounts-pocket') }}</h4></a>
<ul class="mzp-u-list-styled">
<li>{{ ftl('firefox-accounts-save-articles') }}</li>
<li>{{ ftl('firefox-accounts-read-in-a') }}</li>
</ul>
{% endif %}
janbrasna marked this conversation as resolved.
Show resolved Hide resolved
</div>

<p class="c-accounts-tagline">{{ ftl('firefox-accounts-get-it-all-on-every') }}</p>
Expand Down
6 changes: 3 additions & 3 deletions bedrock/mozorg/templates/mozorg/home/home-new.html
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
{% endif %}
{% endblock %}

{% set utm_params = '?utm_source=www.mozilla.org&utm_campaign=homepage&utm_medium=referral' %}
{% set utm_params = '?utm_source=www.mozilla.org&utm_medium=referral&utm_campaign=homepage' %}
janbrasna marked this conversation as resolved.
Show resolved Hide resolved

{% block content %}

Expand Down Expand Up @@ -172,7 +172,7 @@ <h2>{{ ftl('home-mozilla-makes-privacy') }}</h2>
),
body=True,
) %}
<a href="https://monitor.mozilla.org/" class="mzp-c-button mzp-t-secondary" id="homepage-get-monitor" data-cta-text="Get Mozilla Monitor" data-cta-type="link" rel="external noopener">{{ ftl('home-cta-get-monitor')}}</a>
<a href="https://monitor.mozilla.org/{{ utm_params }}" rel="external noopener" class="mzp-c-button mzp-t-secondary" id="homepage-get-monitor" data-cta-text="Get Mozilla Monitor" data-cta-type="link">{{ ftl('home-cta-get-monitor')}}</a>
{% endcall %}
{% endif %}
</ul>
Expand Down Expand Up @@ -206,7 +206,7 @@ <h2>{{ ftl('home-mozilla-makes-privacy') }}</h2>
) %}
<h2>{{ ftl('home-is-mozilla-a-corporation')}}</h2>
<p>{{ ftl('home-mozilla-consists-of') }}</p>
<a href="https://foundation.mozilla.org/" class="mzp-c-button" rel="external noopener">
<a href="https://foundation.mozilla.org/{{ utm_params }}" rel="external noopener" class="mzp-c-button">
<span>{{ ftl('home-learn-about-mofo') }}</span>
<img src="{{ static('img/home/2023/external-link-white.png') }}" alt="" class="external-link-white">
<img src="{{ static('img/home/2023/external-link-black.png') }}" alt="" class="external-link-black">
Expand Down