Skip to content

Commit

Permalink
fixup! chore: Add matamo integration doc
Browse files Browse the repository at this point in the history
  • Loading branch information
farhaanbukhsh committed Jan 3, 2025
1 parent f507ce1 commit 2c8aa46
Showing 1 changed file with 9 additions and 17 deletions.
26 changes: 9 additions & 17 deletions source/site_ops/how-tos/matamo-analytics.rst
Original file line number Diff line number Diff line change
@@ -1,28 +1,20 @@
Configuring Matamo Analytics
#############################

In addition to Google Analytics the Open edX platform is flexible enough to support different analytics
tool.
In addition to Google Analytics, the Open edX platform is flexible enough to support different analytics tools.

In order to inject various analytics there is a provision to add them to head or body using `head-extra.html`, `body-initial.html` or
`body-extra.html`.
To inject various analytics, there is a provision to add them to the head or body using head-extra.html, body-initial.html, or body-extra.html.

One needs to be using comprehensive theme in order to use these templates. More information can be found at `README.rst under themes
in edx-platform <https://github.com/openedx/edx-platform/blob/master/themes/README.rst>`_.
One needs to be using the comprehensive theme to use these templates. More information can be found in the `README.rst under themes in edx-platform <https://github.com/openedx/edx-platform/blob/master/themes/README.rst>`_.

Let us walk you through integrating Matamo to the platform:
Let us walk you through integrating Matamo into the platform:

Matamo demands to be included under the head tag of the page hence we will be using `head-extra.html` to include the analytics
script.
Matamo needs to be included under the head tag of the page; hence, we will use head-extra.html to include the analytics script.

1. Create `head-extra.html` file under {theme}/lms/templates/.
2. Add the script given by the platform in the file.
3. Apply the theme and we are good to go.
1. Create the head-extra.html file under {theme}/lms/templates/.
2. Add the script provided by the platform to the file.
3. Apply the theme, and we are good to go.

Note::

This will only be applied to the pages served by LMS and would not be supported by different MFEs used by the platform.
Hence, for introducing the same you need to create a custom component and put it in a slot. You can have a look at `frontend-footer-component <https://github.com/openedx/frontend-component-footer>`_.



This will only be applied to the pages served by LMS and would not be supported by different MFEs used by the platform. Hence, to introduce the same, you need to create a custom component and put it in a slot. You can have a look at the `frontend-footer-component <https://github.com/openedx/frontend-component-footer>`_.

0 comments on commit 2c8aa46

Please sign in to comment.