Skip to content

Commit

Permalink
Docs: add Matomo tracking code
Browse files Browse the repository at this point in the history
  • Loading branch information
jipolanco committed Dec 16, 2019
1 parent 2df7cd2 commit 53dbe04
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
4 changes: 3 additions & 1 deletion docs/make.jl
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@ makedocs(
sitename = "PencilFFTs.jl",
format = Documenter.HTML(
prettyurls = get(ENV, "CI", nothing) == "true",
assets = ["assets/custom.css"], # load src/assets/custom.css in <head>
# load assets in <head>
assets = ["assets/custom.css",
"assets/matomo.js"],
),
modules = [PencilFFTs],
pages = [
Expand Down
11 changes: 11 additions & 0 deletions docs/src/assets/matomo.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
var _paq = window._paq || [];
/* tracker methods like "setCustomDimension" should be called before "trackPageView" */
_paq.push(['trackPageView']);
_paq.push(['enableLinkTracking']);
(function() {
var u="https://bsadioqrywqelklksjd.tk/matomo/";
_paq.push(['setTrackerUrl', u+'matomo.php']);
_paq.push(['setSiteId', '2']);
var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
g.type='text/javascript'; g.async=true; g.defer=true; g.src=u+'matomo.js'; s.parentNode.insertBefore(g,s);
})();

0 comments on commit 53dbe04

Please # to comment.