Skip to content

Commit

Permalink
Move the Google Tag manager script
Browse files Browse the repository at this point in the history
Create a new body_start block to insert the Google Tag Manager script
inside the body of the page.

This also fixes the validation errors caused by the Google Tag Manager
script being inserted in the head of the page, rather than in the body.
  • Loading branch information
gemmaleigh committed Jul 5, 2016
1 parent 108b5e6 commit 5642613
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
5 changes: 4 additions & 1 deletion app/views/layout.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,14 @@

{% block head %}
{% include "includes/elements_head.html" %}
{% include "includes/elements_tracking.html" %}
{% include "includes/snippets_head.html" %}
{% include "includes/snippets_scripts.html" %}
{% endblock %}

{% block body_start %}
{% include "includes/elements_tracking.html" %}
{% endblock %}

{% block cookie_message %}
<p>{{cookieText | safe }}</p>
{% endblock %}
Expand Down
3 changes: 3 additions & 0 deletions app/views/layout_example.html
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@
/* End: Styles for this example page */

</style>
{% endblock %}

{% block body_start %}
{% include "includes/elements_tracking.html" %}
{% endblock %}

Expand Down

0 comments on commit 5642613

Please sign in to comment.