From 81d22e60773dc12ba238e9a01e320f72fa3a8acd Mon Sep 17 00:00:00 2001 From: Benjamin Meichsner Date: Sun, 21 Sep 2014 14:01:21 +0200 Subject: [PATCH] Allow adding tracking code for webstatistics service. E.g. piwik. --- app/views/layouts/_header.html.haml | 3 ++- config/app_config.yml.SAMPLE | 5 +++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/app/views/layouts/_header.html.haml b/app/views/layouts/_header.html.haml index d84a4f47..974ce8f2 100644 --- a/app/views/layouts/_header.html.haml +++ b/app/views/layouts/_header.html.haml @@ -8,7 +8,7 @@ = csrf_meta_tags = stylesheet_link_tag "application", :media => "all" //%link(href="images/favicon.ico" rel="shortcut icon") - + = yield(:head) = foodcoop_css_tag @@ -25,3 +25,4 @@ I18n.locale = "#{I18n.locale}"; I18n.fallbacks = true; = yield(:javascript) + = raw FoodsoftConfig[:webstats_tracking_code] diff --git a/config/app_config.yml.SAMPLE b/config/app_config.yml.SAMPLE index a455f113..46308a02 100644 --- a/config/app_config.yml.SAMPLE +++ b/config/app_config.yml.SAMPLE @@ -123,6 +123,11 @@ default: &defaults encoding: utf8 socket: /opt/lampp/var/mysql/mysql.sock + # Uncomment to add tracking code for web statistics, e.g. piwik + #webstats_tracking_code: | + # + # ...... + development: <<: *defaults