function set($name) { //@todo rename this to just set $newPlace = 'app/themes/' . $name; D::log(LOC . '/' . $newPlace, 'new Place'); if(is_dir(LOC . '/' . $newPlace)) { if(substr(URL, -1) == '?') { T::$url = $this->themeUrl = substr(URL, 0, -1) . $newPlace; } else { T::$url = $this->themeUrl = URL . $newPlace; } T::$loc = LOC . '/' . $newPlace; //$this->libs->Config->set('site', 'theme', $newPlace); return true; } else { D::error('Theme doesn\'t exist'); } }
function set($name) { //@todo rename this to just set $newPlace = 'themes/' . $name; D::log($name, 'Theme Set'); // D::log(URL, 'URL'); if(is_dir(APP_FOLDER . '/' . $newPlace)) { if(defined('URL')) { if(substr(URL, -1) == '?') { T::$url = $this->themeUrl = substr(URL, 0, -1) . APP_NAME . '/' . $newPlace . '/'; } else { T::$url = $this->themeUrl = URL . APP_NAME . '/' . $newPlace . '/'; } } T::$loc = $this->themeLoc = APP_FOLDER . '/' . $newPlace; //$this->libs->Config->set('site', 'theme', $newPlace); return true; } else { D::error('Theme doesn\'t exist'); } }