Gabriel commited on
Commit
3f1d08a
·
verified ·
1 Parent(s): 29e1747

Update app/main.py

Browse files
Files changed (1) hide show
  1. app/main.py +11 -5
app/main.py CHANGED
@@ -37,16 +37,22 @@ def load_markdown(language, section, content_dir="app/content"):
37
 
38
 
39
  matomo = """
40
- <!-- Matomo Tag Manager -->
41
  <script>
42
- var _mtm = window._mtm = window._mtm || [];
43
- _mtm.push({'mtm.startTime': (new Date().getTime()), 'event': 'mtm.Start'});
 
 
44
  (function() {
 
 
 
45
  var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
46
- g.async=true; g.src='https://analys.riksarkivet.se/js/container_EgtcZ6nV.js'; s.parentNode.insertBefore(g,s);
47
  })();
48
  </script>
49
- <!-- End Matomo Tag Manager -->
 
50
  """
51
 
52
  with gr.Blocks(title="HTRflow", theme=theme, css=css, head=matomo) as demo:
 
37
 
38
 
39
  matomo = """
40
+ <!-- Matomo -->
41
  <script>
42
+ var _paq = window._paq = window._paq || [];
43
+ /* tracker methods like "setCustomDimension" should be called before "trackPageView" */
44
+ _paq.push(['trackPageView']);
45
+ _paq.push(['enableLinkTracking']);
46
  (function() {
47
+ var u="https://matomo.riksarkivet.se/";
48
+ _paq.push(['setTrackerUrl', u+'matomo.php']);
49
+ _paq.push(['setSiteId', '25']);
50
  var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
51
+ g.async=true; g.src=u+'matomo.js'; s.parentNode.insertBefore(g,s);
52
  })();
53
  </script>
54
+ <noscript><p><img referrerpolicy="no-referrer-when-downgrade" src="https://matomo.riksarkivet.se/matomo.php?idsite=25&amp;rec=1" style="border:0;" alt="" /></p></noscript>
55
+ <!-- End Matomo Code -->
56
  """
57
 
58
  with gr.Blocks(title="HTRflow", theme=theme, css=css, head=matomo) as demo: