Files
2026-07-01 16:44:17 +03:00

41 lines
928 B
PHP

<?php namespace Project\Controllers;
use DB, Import, URL, Cookie, Session, Method, FOLDER;
/**
* Created By: Osman Erkan
* Created Date: 2017-09-10
* Update Date: 2023-02-10
*/
class Setting extends Controller{
function __construct(){if (!USERID) {redirect(URL::base('panel'));}}
function main() {
$result = DB::orderBy('title', 'asc')->settingsResult();
//output($result);
if (method::post()) {$this->panel->setting_update(method::post());}
View::list($result);
}
function logo(){
if (method::post()) {$this->panel->logo_update(method::post());}
}
function favicon(){
if (method::post()) {$this->panel->favicon_update(method::post());}
}
function theme(){
if (method::post()) {$this->panel->theme_update(method::post());}
}
function selectLogo(){
$value = Method::post('value');
DB::where('title', 'logo')->update('settings',[
'value' => $value,
]);
echo DB::error();
}
}