mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-09-06 17:38:25 -04:00
Update the javascript to work for www, non-www, and localhost
This commit is contained in:
@@ -127,10 +127,10 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
if (window.GOVUK.cookie('_ga') !== null) {
|
if (window.GOVUK.cookie('_ga') !== null) {
|
||||||
document.cookie = '_ga' + '=;expires=' + new Date() + ';domain=.' + window.location.hostname + ';path=/';
|
document.cookie = '_ga' + '=;expires=' + new Date() + ';domain=' + window.location.hostname.replace(/^www\./, '.') + ';path=/';
|
||||||
}
|
}
|
||||||
if (window.GOVUK.cookie('_gid') !== null) {
|
if (window.GOVUK.cookie('_gid') !== null) {
|
||||||
document.cookie = '_gid' + '=;expires=' + new Date() + ';domain=.' + window.location.hostname + ';path=/';
|
document.cookie = '_gid' + '=;expires=' + new Date() + ';domain=' + window.location.hostname.replace(/^www\./, '.') + ';path=/';
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
@@ -237,10 +237,10 @@
|
|||||||
<!--<![endif]-->
|
<!--<![endif]-->
|
||||||
<script>
|
<script>
|
||||||
if (window.GOVUK.cookie('_ga') !== null) {
|
if (window.GOVUK.cookie('_ga') !== null) {
|
||||||
document.cookie = '_ga' + '=;expires=' + new Date() + ';domain=.' + window.location.hostname + ';path=/';
|
document.cookie = '_ga' + '=;expires=' + new Date() + ';domain=' + window.location.hostname.replace(/^www\./, '.') + ';path=/';
|
||||||
}
|
}
|
||||||
if (window.GOVUK.cookie('_gid') !== null) {
|
if (window.GOVUK.cookie('_gid') !== null) {
|
||||||
document.cookie = '_gid' + '=;expires=' + new Date() + ';domain=.' + window.location.hostname + ';path=/';
|
document.cookie = '_gid' + '=;expires=' + new Date() + ';domain=' + window.location.hostname.replace(/^www\./, '.') + ';path=/';
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|||||||
@@ -128,10 +128,10 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
if (window.GOVUK.cookie('_ga') !== null) {
|
if (window.GOVUK.cookie('_ga') !== null) {
|
||||||
document.cookie = '_ga' + '=;expires=' + new Date() + ';domain=.' + window.location.hostname + ';path=/';
|
document.cookie = '_ga' + '=;expires=' + new Date() + ';domain=' + window.location.hostname.replace(/^www\./, '.') + ';path=/';
|
||||||
}
|
}
|
||||||
if (window.GOVUK.cookie('_gid') !== null) {
|
if (window.GOVUK.cookie('_gid') !== null) {
|
||||||
document.cookie = '_gid' + '=;expires=' + new Date() + ';domain=.' + window.location.hostname + ';path=/';
|
document.cookie = '_gid' + '=;expires=' + new Date() + ';domain=' + window.location.hostname.replace(/^www\./, '.') + ';path=/';
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user