<?php
define("MODE", dirname(__FILE__));
define("BASEURL", "index.php?m=dianpu");
define("APPLICATION", MODE . "/application");

/*风格模板*/
define("TEMPLATE_VIEWER", MODE . "/template/");
define("THEMES_VIEWER", MODE . "/themes/");

if (defined('FRAMEWORK_ADMIN')) {
	//后台控制器
	list($controller,$action) = array($adminjob,$action);
	define("APP_VIEWER", APPLICATION . "/admin/viewer/");
	define("APP_CONTROLLER", APPLICATION . "/admin/controller/");
	$configs = array('c' => $controller,'a' => $action);
} else {
	//前台控制器
	define("APP_VIEWER", APPLICATION . "/front/viewer/");
	define("APP_CONTROLLER", APPLICATION . "/front/controller/");
	$configs = array('c' => $_GET['c'],'a' => $_GET['a']);
}
$router = L::loadClass("router", "framework");
$router->run($configs);