Esempio n. 1
1
File: boot.php Progetto: awisu2/Aqua
function boot()
{
    try {
        // configで動作
        $Rooter = new Rooter();
        $matches = $Rooter->matche_pattern();
        $controller = ucfirst($matches['controller']);
        $method = $matches['method'];
        a();
        // controllerの読み込みと実行
        require_controller($controller);
        $class_name = "\\Aqua\\Controller\\{$controller}";
        $Class = new $class_name();
        $Class->{$method}();
    } catch (Exception $e) {
        echo "gtetea";
        var_dump($e->getMessage());
    }
}
 public function __construct()
 {
     $rooter = new Rooter();
     $this->controller = $rooter->get_controller();
     $this->method = $rooter->get_method();
     $this->params = $rooter->get_params();
 }
Esempio n. 3
0
 public function rooter()
 {
     $rooter = new Rooter();
     $page = $rooter->returnPage();
     if ($page) {
         $n = new View($page);
     }
 }