Merge branch 'feature/piwik' into 'develop'

New tracking_code setting that inserts HTML code in the footer of every page

See merge request !163
This commit is contained in:
Olivier Perez 2016-12-30 15:59:40 +01:00
commit 61e3d0735f
3 changed files with 7 additions and 0 deletions

View File

@ -86,6 +86,7 @@ const TIME_EDIT_LINK_EMAIL = 60;
$config = [ $config = [
/* general config */ /* general config */
'use_smtp' => true, // use email for polls creation/modification/responses notification 'use_smtp' => true, // use email for polls creation/modification/responses notification
'tracking_code' => '', // add HTML code to every page, useful for tools like Piwik
/* home */ /* home */
'show_what_is_that' => true, // display "how to use" section 'show_what_is_that' => true, // display "how to use" section
'show_the_software' => true, // display technical information about the software 'show_the_software' => true, // display technical information about the software

View File

@ -33,6 +33,9 @@ $smarty->assign('use_nav_js', strstr($_SERVER['SERVER_NAME'], 'framadate.org'));
$smarty->assign('locale', $locale); $smarty->assign('locale', $locale);
$smarty->assign('langs', $ALLOWED_LANGUAGES); $smarty->assign('langs', $ALLOWED_LANGUAGES);
$smarty->assign('date_format', $date_format); $smarty->assign('date_format', $date_format);
if (isset($config['tracking_code'])) {
$smarty->assign('tracking_code', $config['tracking_code']);
}
// Dev Mode // Dev Mode
if (isset($_SERVER['FRAMADATE_DEVMODE']) && $_SERVER['FRAMADATE_DEVMODE']) { if (isset($_SERVER['FRAMADATE_DEVMODE']) && $_SERVER['FRAMADATE_DEVMODE']) {

View File

@ -37,5 +37,8 @@
</main> </main>
</div> <!-- .container --> </div> <!-- .container -->
{if isset($tracking_code)}
{$tracking_code}
{/if}
</body> </body>
</html> </html>