mirror of
https://github.com/e107inc/e107.git
synced 2025-08-02 12:48:26 +02:00
Fixes #2331 - themecss pref was being deleted when saving theme prefs.
This commit is contained in:
@@ -2496,6 +2496,9 @@ class themeHandler
|
|||||||
// $this->showThemes('admin');
|
// $this->showThemes('admin');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @todo add admin log
|
||||||
|
*/
|
||||||
function setStyle()
|
function setStyle()
|
||||||
{
|
{
|
||||||
global $pref,$e107cache;
|
global $pref,$e107cache;
|
||||||
@@ -2503,16 +2506,21 @@ class themeHandler
|
|||||||
$ns = e107::getRender();
|
$ns = e107::getRender();
|
||||||
$mes = e107::getMessage();
|
$mes = e107::getMessage();
|
||||||
|
|
||||||
//TODO adminlog
|
$themeCSS = vartrue($_POST['themecss'],'style.css');
|
||||||
e107::getConfig()->setPosted('themecss', $_POST['themecss'])->setPosted('sitetheme_deflayout', $_POST['layout_default']);
|
$themeLayout = vartrue($_POST['layout_default'], 'default');
|
||||||
|
|
||||||
|
e107::getConfig()->setPosted('themecss',$themeCSS)->setPosted('sitetheme_deflayout', $themeLayout);
|
||||||
|
|
||||||
$msg = $this->setThemeConfig();
|
$msg = $this->setThemeConfig();
|
||||||
|
|
||||||
if($msg)
|
if($msg)
|
||||||
{
|
{
|
||||||
$mes->add(TPVLAN_37, E_MESSAGE_SUCCESS);
|
$mes->add(TPVLAN_37, E_MESSAGE_SUCCESS);
|
||||||
if(is_array($msg))
|
if(is_array($msg))
|
||||||
$mes->add($msg[0], $msg[1]);
|
$mes->add($msg[0], $msg[1]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function setAdminStyle()
|
function setAdminStyle()
|
||||||
|
Reference in New Issue
Block a user