whitespace
This commit is contained in:
parent
1d80c33207
commit
d60c2b1621
@ -1,11 +1,13 @@
|
|||||||
<?php
|
<?php
|
||||||
|
|
||||||
if(! $a->install) {
|
if(! $a->install) {
|
||||||
|
|
||||||
// Get the UID of the channel owner
|
// Get the UID of the channel owner
|
||||||
$uid = get_theme_uid();
|
$uid = get_theme_uid();
|
||||||
|
|
||||||
if($uid)
|
if($uid) {
|
||||||
load_pconfig($uid,'redbasic');
|
load_pconfig($uid,'redbasic');
|
||||||
|
}
|
||||||
|
|
||||||
// Load the owners pconfig
|
// Load the owners pconfig
|
||||||
$nav_bg = get_pconfig($uid, "redbasic", "nav_bg");
|
$nav_bg = get_pconfig($uid, "redbasic", "nav_bg");
|
||||||
@ -46,18 +48,20 @@ if(! $a->install) {
|
|||||||
// Setting $schema to '' wasn't working for some reason, so we'll check it's
|
// Setting $schema to '' wasn't working for some reason, so we'll check it's
|
||||||
// not --- like the mobile theme does instead.
|
// not --- like the mobile theme does instead.
|
||||||
|
|
||||||
|
|
||||||
// Allow layouts to over-ride the schema
|
// Allow layouts to over-ride the schema
|
||||||
|
|
||||||
if($_REQUEST['schema'])
|
if($_REQUEST['schema']) {
|
||||||
$schema = $_REQUEST['schema'];
|
$schema = $_REQUEST['schema'];
|
||||||
|
}
|
||||||
|
|
||||||
if (($schema) && ($schema != '---')) {
|
if (($schema) && ($schema != '---')) {
|
||||||
|
|
||||||
// Check it exists, because this setting gets distributed to clones
|
// Check it exists, because this setting gets distributed to clones
|
||||||
if(file_exists('view/theme/redbasic/schema/' . $schema . '.php')) {
|
if(file_exists('view/theme/redbasic/schema/' . $schema . '.php')) {
|
||||||
$schemefile = 'view/theme/redbasic/schema/' . $schema . '.php';
|
$schemefile = 'view/theme/redbasic/schema/' . $schema . '.php';
|
||||||
require_once ($schemefile);
|
require_once ($schemefile);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(file_exists('view/theme/redbasic/schema/' . $schema . '.css')) {
|
if(file_exists('view/theme/redbasic/schema/' . $schema . '.css')) {
|
||||||
$schemecss = file_get_contents('view/theme/redbasic/schema/' . $schema . '.css');
|
$schemecss = file_get_contents('view/theme/redbasic/schema/' . $schema . '.css');
|
||||||
}
|
}
|
||||||
@ -67,19 +71,20 @@ if(! $a->install) {
|
|||||||
// If we haven't got a schema, load the default. We shouldn't touch this - we
|
// If we haven't got a schema, load the default. We shouldn't touch this - we
|
||||||
// should leave it for admins to define for themselves.
|
// should leave it for admins to define for themselves.
|
||||||
if (! $schema) {
|
if (! $schema) {
|
||||||
|
|
||||||
if(file_exists('view/theme/redbasic/schema/default.php')) {
|
if(file_exists('view/theme/redbasic/schema/default.php')) {
|
||||||
$schemefile = 'view/theme/redbasic/schema/default.php';
|
$schemefile = 'view/theme/redbasic/schema/default.php';
|
||||||
require_once ($schemefile);
|
require_once ($schemefile);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(file_exists('view/theme/redbasic/schema/default.css')) {
|
if(file_exists('view/theme/redbasic/schema/default.css')) {
|
||||||
$schemecss = file_get_contents('view/theme/redbasic/schema/default.css');
|
$schemecss = file_get_contents('view/theme/redbasic/schema/default.css');
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
//Set some defaults - we have to do this after pulling owner settings, and we have to check for each setting
|
//Set some defaults - we have to do this after pulling owner settings, and we have to check for each setting
|
||||||
//individually. If we don't, we'll have problems if a user has set one, but not all options.
|
//individually. If we don't, we'll have problems if a user has set one, but not all options.
|
||||||
|
|
||||||
if (! $nav_bg)
|
if (! $nav_bg)
|
||||||
$nav_bg = "#222";
|
$nav_bg = "#222";
|
||||||
if (! $nav_gradient_top)
|
if (! $nav_gradient_top)
|
||||||
@ -145,8 +150,8 @@ if(! $a->install) {
|
|||||||
|
|
||||||
// Apply the settings
|
// Apply the settings
|
||||||
if(file_exists('view/theme/redbasic/css/style.css')) {
|
if(file_exists('view/theme/redbasic/css/style.css')) {
|
||||||
$x = file_get_contents('view/theme/redbasic/css/style.css');
|
|
||||||
|
|
||||||
|
$x = file_get_contents('view/theme/redbasic/css/style.css');
|
||||||
|
|
||||||
// left aside is 231px + converse width
|
// left aside is 231px + converse width
|
||||||
$main_width = (231 + intval($converse_width));
|
$main_width = (231 + intval($converse_width));
|
||||||
@ -189,6 +194,7 @@ $options = array (
|
|||||||
);
|
);
|
||||||
|
|
||||||
echo str_replace(array_keys($options), array_values($options), $x);
|
echo str_replace(array_keys($options), array_values($options), $x);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if($narrow_navbar && file_exists('view/theme/redbasic/css/narrow_navbar.css')) {
|
if($narrow_navbar && file_exists('view/theme/redbasic/css/narrow_navbar.css')) {
|
||||||
|
Reference in New Issue
Block a user