Browse Source

Vier: Added config.php

pull/914/head
Michael Vogel 7 years ago
parent
commit
a4ecf74a5d
2 changed files with 56 additions and 0 deletions
  1. +52
    -0
      view/theme/vier/config.php
  2. +4
    -0
      view/theme/vier/flat.css

+ 52
- 0
view/theme/vier/config.php View File

@ -0,0 +1,52 @@
<?php
/**
* Theme settings
*/
function theme_content(&$a){
if(!local_user())
return;
$style = get_pconfig(local_user(), 'vier', 'style');
return vier_form($a,$style);
}
function theme_post(&$a){
if(! local_user())
return;
if (isset($_POST['vier-settings-submit'])){
set_pconfig(local_user(), 'vier', 'style', $_POST['vier_style']);
}
}
function theme_admin(&$a){
$style = get_config('vier', 'style');
return vier_form($a,$style);
}
function theme_admin_post(&$a){
if (isset($_POST['vier-settings-submit'])){
set_config('vier', 'style', $_POST['vier_style']);
}
}
function vier_form(&$a, $style){
$styles = array(
"shadow"=>"Shadow",
"flat"=>"Flat"
);
$t = get_markup_template("theme_settings.tpl" );
$o .= replace_macros($t, array(
'$submit' => t('Submit'),
'$baseurl' => $a->get_baseurl(),
'$title' => t("Theme settings"),
'$style' => array('vier_style',t ('Set style'),$style,'',$styles),
));
return $o;
}

+ 4
- 0
view/theme/vier/flat.css View File

@ -0,0 +1,4 @@
*{ box-shadow: 0 0 0 0 !important;}
body, section { background-color: #ffffff !important;}
#profile-jot-form { background-color: #ffffff !important;}
.dspr, .twit, .pump, .dfrn { background-color: #ffffff !important;}

Loading…
Cancel
Save