aboutsummaryrefslogtreecommitdiffstats
path: root/index.php
diff options
context:
space:
mode:
authorMike Macgirvin <mike@macgirvin.com>2010-08-16 05:23:26 -0700
committerMike Macgirvin <mike@macgirvin.com>2010-08-16 05:23:26 -0700
commit30e3a65c0f15f2cbcc538b35c18b1f60490fda9b (patch)
tree5f702db316822d065442ba0e3983272deab861ac /index.php
parent4bcf38029656fa3ad2e1914f531491ef90320c23 (diff)
downloadvolse-hubzilla-30e3a65c0f15f2cbcc538b35c18b1f60490fda9b.tar.gz
volse-hubzilla-30e3a65c0f15f2cbcc538b35c18b1f60490fda9b.tar.bz2
volse-hubzilla-30e3a65c0f15f2cbcc538b35c18b1f60490fda9b.zip
full theming support
Diffstat (limited to 'index.php')
-rw-r--r--index.php9
1 files changed, 8 insertions, 1 deletions
diff --git a/index.php b/index.php
index 52ea58374..c3933dc8b 100644
--- a/index.php
+++ b/index.php
@@ -26,6 +26,7 @@ $a->init_pagehead();
session_start();
+
if((x($_SESSION,'authenticated')) || (x($_POST['auth-params'])))
require("auth.php");
@@ -106,12 +107,18 @@ $a->page['content'] .= $debug_text;
if($a->module != 'install')
require_once("nav.php");
+$a->page['htmlhead'] = replace_macros($a->page['htmlhead'], array(
+ '$stylesheet' => $a->get_baseurl() . '/view/theme/'
+ . ((x($_SESSION,'theme')) ? $_SESSION['theme'] : 'default')
+ . '/style.css'
+ ));
+
$page = $a->page;
$profile = $a->profile;
header("Content-type: text/html; charset=utf-8");
+
$template = "view/"
- . ((x($a->page,'theme')) ? $a->page['theme'] . '/' : "" )
. ((x($a->page,'template')) ? $a->page['template'] : 'default' )
. ".php";