Файл: adultscript-2.0.3-pro/files/admin/modules/channel/channel.php
Строк: 60
<?php
defined('_VALID') or die('Restricted Access!');
class VModule_Admin_channel
{
private $components = array(
'manage' => 1,
'config' => 1,
'add' => 1,
'edit' => 1,
'network_add' => 1,
'network_edit' => 1,
'network_manage' => 1,
'rebuild' => 1
);
protected $db;
public function __construct()
{
$this->db = VF::factory('database');
}
public function render()
{
$component = VUri::component('manage');
if (isset($this->components[$component]) && $this->components[$component] === 1) {
$component_class = 'VComponent_Admin_channel_'.$component;
try {
require ADMIN_DIR.'/modules/channel/components/'.$component.'.php';
} catch (Exception $e) {
throw new VException($e);
}
$obj = new $component_class();
$obj->render();
} else {
die('Invalid admin channel component specified!');
}
}
}
?>