示例#1
0
 * @license    GNU General Public License version 2 or later; see LICENSE
 *
 */
error_reporting(0);
session_start();
define('ROOT', dirname(__FILE__));
define('DS', DIRECTORY_SEPARATOR);
include_once ROOT . DS . 'includes' . DS . 'functions.php';
// call language
$dg = new dg();
$lang = $dg->lang();
$site_url = $dg->url();
// get design
$cache = $dg->cache('admin');
$path = ROOT . DS . 'cache' . DS . 'admin';
$files = $dg->getFiles($path);
$designs = array();
if ($files !== false) {
    $i = 0;
    foreach ($files as $file) {
        $key = str_replace('.txt', '', $file);
        $designs[$key] = $cache->get($key);
    }
}
// Paginition.
$url = $_SERVER['REQUEST_URI'];
$params = explode('admin.php/', $url);
if (count($params) > 1) {
    $segment = (int) $params[1];
} else {
    $segment = '';