|
|
|
@ -11,6 +11,37 @@ function theme_content(&$a){
|
|
|
|
|
|
|
|
|
|
$align = get_pconfig(local_user(), 'quattro', 'align' ); |
|
|
|
|
$color = get_pconfig(local_user(), 'quattro', 'color' ); |
|
|
|
|
|
|
|
|
|
return quattro_form($a,$align, $color); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
function theme_post(&$a){ |
|
|
|
|
if(! local_user()) |
|
|
|
|
return; |
|
|
|
|
|
|
|
|
|
if (isset($_POST['quattro-settings-submit'])){ |
|
|
|
|
set_pconfig(local_user(), 'quattro', 'align', $_POST['quattro_align']); |
|
|
|
|
set_pconfig(local_user(), 'quattro', 'color', $_POST['quattro_color']); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function theme_admin(&$a){ |
|
|
|
|
$align = get_config('quattro', 'align' ); |
|
|
|
|
$color = get_config('quattro', 'color' ); |
|
|
|
|
|
|
|
|
|
return quattro_form($a,$align, $color); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
function theme_admin_post(&$a){ |
|
|
|
|
if (isset($_POST['quattro-settings-submit'])){ |
|
|
|
|
set_config('quattro', 'align', $_POST['quattro_align']); |
|
|
|
|
set_config('quattro', 'color', $_POST['quattro_color']); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function quattro_form(&$a, $align, $color){ |
|
|
|
|
$colors = array( |
|
|
|
|
"dark"=>"Quattro", |
|
|
|
|
"green"=>"Green" |
|
|
|
@ -26,14 +57,3 @@ function theme_content(&$a){
|
|
|
|
|
)); |
|
|
|
|
return $o; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
function theme_post(&$a){ |
|
|
|
|
if(! local_user()) |
|
|
|
|
return; |
|
|
|
|
|
|
|
|
|
if (isset($_POST['quattro-settings-submit'])){ |
|
|
|
|
set_pconfig(local_user(), 'quattro', 'align', $_POST['quattro_align']); |
|
|
|
|
set_pconfig(local_user(), 'quattro', 'color', $_POST['quattro_color']); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|