aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorfriendica <info@friendica.com>2014-03-02 16:46:34 -0800
committerfriendica <info@friendica.com>2014-03-02 16:46:34 -0800
commit895c9411d9393776f2ae4846935e42c31fde41af (patch)
treeb77824215a9e6ca8377aba451adba062cc95201d /include
parente931af830701fdacc64e2cc014aa0057dc91e093 (diff)
downloadvolse-hubzilla-895c9411d9393776f2ae4846935e42c31fde41af.tar.gz
volse-hubzilla-895c9411d9393776f2ae4846935e42c31fde41af.tar.bz2
volse-hubzilla-895c9411d9393776f2ae4846935e42c31fde41af.zip
add choklet template with several defined flavours, two and three column fluid layouts with optional side margins and a region for a blog-style header photo
Diffstat (limited to 'include')
-rw-r--r--include/nav.php39
1 files changed, 22 insertions, 17 deletions
diff --git a/include/nav.php b/include/nav.php
index dd15ff411..4e3d9fbec 100644
--- a/include/nav.php
+++ b/include/nav.php
@@ -8,12 +8,10 @@ function nav(&$a) {
*
*/
- $ssl_state = ((local_user()) ? true : false);
-
if(!(x($a->page,'nav')))
$a->page['nav'] = '';
- $base = $a->get_baseurl($ssl_state);
+ $base = z_root();
$a->page['htmlhead'] .= <<< EOT
<script>$(document).ready(function() {
@@ -33,18 +31,6 @@ EOT;
- /**
- * Placeholder div for popup panel
- */
-
- /**
- *
- * Our network is distributed, and as you visit friends some of the
- * sites look exactly the same - it isn't always easy to know where you are.
- * Display the current site location as a navigation aid.
- *
- */
-
if(local_user()) {
$channel = $a->get_channel();
$observer = $a->get_observer();
@@ -58,6 +44,26 @@ EOT;
$sitelocation = (($myident) ? $myident : $a->get_hostname());
+
+ /**
+ *
+ * Provide a banner/logo/whatever
+ *
+ */
+
+ $banner = get_config('system','banner');
+
+ if($banner === false)
+ $banner = get_config('system','sitename');
+
+ $a->page['header'] .= replace_macros(get_markup_template('hdr.tpl'), array(
+ '$baseurl' => $a->get_baseurl(),
+ '$sitelocation' => $sitelocation,
+ '$langselector' => ((get_config('system','select_language')) ? lang_selector() : ''),
+ '$banner' => $banner
+ ));
+
+
// nav links: array of array('href', 'text', 'extra css classes', 'title')
$nav = Array();
@@ -128,7 +134,7 @@ EOT;
if(($a->config['system']['register_policy'] == REGISTER_OPEN) && (! local_user()) && (! remote_user()))
$nav['register'] = array('register',t('Register'), "", t('Create an account'));
- $help_url = $a->get_baseurl($ssl_state) . '/help';
+ $help_url = z_root() . '/help';
if(! get_config('system','hide_help'))
$nav['help'] = array($help_url, t('Help'), "", t('Help and documentation'));
@@ -209,7 +215,6 @@ EOT;
$a->page['nav'] .= replace_macros($tpl, array(
'$baseurl' => $a->get_baseurl(),
- '$langselector' => ((get_config('system','select_language')) ? lang_selector() : ''),
'$sitelocation' => $sitelocation,
'$nav' => $x['nav'],
'$banner' => $banner,