aboutsummaryrefslogtreecommitdiffstats
path: root/view
diff options
context:
space:
mode:
Diffstat (limited to 'view')
-rw-r--r--view/theme/redbasic/css/fancy.css23
-rw-r--r--view/theme/redbasic/css/mod_page.css4
-rw-r--r--view/theme/redbasic/php/config.php3
-rw-r--r--view/theme/redbasic/php/style.php33
4 files changed, 47 insertions, 16 deletions
diff --git a/view/theme/redbasic/css/fancy.css b/view/theme/redbasic/css/fancy.css
index 277ea5596..2da9d68d1 100644
--- a/view/theme/redbasic/css/fancy.css
+++ b/view/theme/redbasic/css/fancy.css
@@ -81,3 +81,26 @@ ul.menu-popup a:hover {
background-color: #eec;
color: #f00;
}
+
+section {
+left: 0px;
+width: 800px;
+margin-left: auto;
+margin-right: auto;
+}
+body {background-color: #d00 !important;}
+
+.page-content-wrapper {background: #fff;
+ color: #000;
+ border-radius: 20px;
+ box-shadow: 5px 5px 5px #111;
+}
+
+h3.page-title {
+padding-top: 30px;
+ color: #033}
+.page-body {padding: 40px;}
+
+.page-body strong {color: #033;}
+
+.nav-links {margin-top: 5px;}
diff --git a/view/theme/redbasic/css/mod_page.css b/view/theme/redbasic/css/mod_page.css
index 26c16b88c..37f597fac 100644
--- a/view/theme/redbasic/css/mod_page.css
+++ b/view/theme/redbasic/css/mod_page.css
@@ -1,3 +1,4 @@
+/*
section {
left: 0px;
width: 800px;
@@ -19,4 +20,5 @@ padding-top: 30px;
.page-body strong {color: #033;}
-.nav-links {margin-top: 5px;} \ No newline at end of file
+.nav-links {margin-top: 5px;}
+*/ \ No newline at end of file
diff --git a/view/theme/redbasic/php/config.php b/view/theme/redbasic/php/config.php
index 5917b1e36..4e7363362 100644
--- a/view/theme/redbasic/php/config.php
+++ b/view/theme/redbasic/php/config.php
@@ -23,7 +23,7 @@ function theme_content(&$a) {
function theme_post(&$a) {
if(!local_user()) { return; }
-
+
if (isset($_POST['redbasic-settings-submit'])) {
set_pconfig(local_user(), 'redbasic', 'font_size', $_POST['redbasic_font_size']);
set_pconfig(local_user(), 'redbasic', 'line_height', $_POST['redbasic_line_height']);
@@ -37,6 +37,7 @@ function theme_post(&$a) {
set_pconfig(local_user(), 'redbasic', 'colour_scheme', $_POST['redbasic_colour_scheme']);
set_pconfig(local_user(), 'redbasic', 'radius', $_POST['redbasic_radius']);
}
+
}
// We probably don't want these if we're having global settings, but we'll comment out for now, just in case
diff --git a/view/theme/redbasic/php/style.php b/view/theme/redbasic/php/style.php
index aa88443bc..8643925d3 100644
--- a/view/theme/redbasic/php/style.php
+++ b/view/theme/redbasic/php/style.php
@@ -2,7 +2,12 @@
// This needs changing now, if we're going for global settings. Admin settings have been removed in preparation, You *should* just be able to remove all
// the get_config bits, though this is untested.
// We also need to eventually. Use the page owners settings for everybody - get_pconfig(page_owner()) or whatever that would look like.
- load_pconfig(local_user(),'redbasic');
+
+
+ $uid = get_theme_uid();
+
+ if($uid)
+ load_pconfig($uid,'redbasic');
$line_height = false;
$redbasic_font_size = false;
@@ -31,25 +36,25 @@
if($x !== false)
$radius = $x;
- if (local_user()) {
- $line_height = get_pconfig(local_user(), "redbasic","line_height");
- $redbasic_font_size = get_pconfig(local_user(), "redbasic", "font_size");
- $colour = get_pconfig(local_user(), "redbasic", "colour");
- $shadows = get_pconfig(local_user(), "redbasic", "shadow");
- $navcolour = get_pconfig(local_user(), "redbasic", "navcolour");
- $displaystyle = get_pconfig(local_user(), "redbasic", "displaystyle");
- $linkcolour = get_pconfig(local_user(), "redbasic", "linkcolour");
- $shiny = get_pconfig(local_user(), "redbasic", "shiny");
- $x = get_pconfig(local_user(),'redbasic','radius');
+ if ($uid) {
+ $line_height = get_pconfig($uid, "redbasic","line_height");
+ $redbasic_font_size = get_pconfig($uid, "redbasic", "font_size");
+ $colour = get_pconfig($uid, "redbasic", "colour");
+ $shadows = get_pconfig($uid, "redbasic", "shadow");
+ $navcolour = get_pconfig($uid, "redbasic", "navcolour");
+ $displaystyle = get_pconfig($uid, "redbasic", "displaystyle");
+ $linkcolour = get_pconfig($uid, "redbasic", "linkcolour");
+ $shiny = get_pconfig($uid, "redbasic", "shiny");
+ $x = get_pconfig($uid,'redbasic','radius');
if($x !== false)
$radius = $x;
- if (! feature_enabled(local_user(),'expert')) {$colour_scheme = get_pconfig(local_user(), "redbasic", "colour_scheme");}
+ if (! feature_enabled($uid,'expert')) {$colour_scheme = get_pconfig($uid, "redbasic", "colour_scheme");}
}
// In non-expert mode, we just let them choose font size, line height, and a colour scheme. A colour scheme is just a pre-defined set of the above variables.
// But only apply these settings in non-expert mode to prevent confusion when turning expert mode on and off.
- if(! feature_enabled(local_user(),'expert')) {
+ if(! feature_enabled($uid,'expert')) {
if ($colour_scheme === 'fancyred') {$shadows = true; $navcolour = 'black'; $displaystyle = 'fancy'; $linkcolour = 'f00'; $shiny = "opaque";}
// Dark themes are very different - we need to do some of these from scratch, so don't bother setting vars for anything else
if ($colour_scheme === 'dark') {$colour = 'dark'; $navcolour = 'black';}
@@ -59,7 +64,7 @@
}
// This is probably the easiest place to apply global settings. Don't bother with site line height and such. Instead, check pconfig for global user settings.
-// eg, if ($redbasic_font_size === false) {$redbasic_font_size = get_pconfig(local_user(), "global", "font_size"); If it's not set, we'll just use the CSS with no changes.
+// eg, if ($redbasic_font_size === false) {$redbasic_font_size = get_pconfig($uid, "global", "font_size"); If it's not set, we'll just use the CSS with no changes.
// Then all you need to do is add a "Global Settings" tab to settings/display, and make an equivalent of theme_settings.tpl and config.php to be loaded there. Easy.
if ($line_height === false) {$line_height = $site_line_height;}