From: Dan Untenzu <untenzu@webit.de> Date: Tue, 17 Jan 2017 14:13:13 +0000 (+0100) Subject: [FEATURE] Enable a custom website title X-Git-Tag: 2.0.0~5 X-Git-Url: https://git.p6c8.net/jirafeau.git/commitdiff_plain/1ed002b703c25eb4c68fab84f3bd70b649d65803?ds=inline [FEATURE] Enable a custom website title Enable the administrator to set a custom title for his installation of Jirafeau, eg. "John Doe Filecenter". --- diff --git a/lib/config.original.php b/lib/config.original.php index cd39bb3..2cc93e7 100644 --- a/lib/config.original.php +++ b/lib/config.original.php @@ -51,6 +51,10 @@ $cfg['organisation'] = 'ACME'; */ $cfg['contactperson'] = ''; +/* Give the installation a title, eg. 'Datahub' or 'John Doe Filehost' + */ +$cfg['title'] = ''; + /* Propose a preview link if file type is previewable */ $cfg['preview'] = true; diff --git a/lib/template/header.php b/lib/template/header.php index 5a365b9..59d145d 100644 --- a/lib/template/header.php +++ b/lib/template/header.php @@ -46,11 +46,16 @@ else } ?> <head> - <title><?php echo t('Jirafeau, your web file repository'); ?></title> + <title><?php echo (true === empty($cfg['title']))? t('Jirafeau, your web file repository') : $cfg['title']; ?></title> <meta http-equiv="Content-Type" content="<?php echo $content_type; ?>" /> <link href="<?php echo $web_root . 'media/' . $style . '/style.css.php'; ?>" rel="stylesheet" type="text/css" /> </head> <body> <script type="text/javascript" language="Javascript" src="lib/functions.js.php"></script> + <div id="content"> -<h1><a href="<?php echo $web_root; ?>"><?php echo t('Jirafeau, your web file repository'); ?></a></h1> + <h1> + <a href="<?php echo $web_root; ?>"> + <?php echo (true === empty($cfg['title']))? t('Jirafeau, your web file repository') : $cfg['title']; ?> + </a> + </h1>