private function PathFinder($path, $route, array $variables = array()) { if ($this->AllowAttempt()) { if ($this->GetFile($path)) { $class = $this->GetClass($path); Layout::Get()->Assign('route', $route); if (call_user_func_array(array(new $class(), $this->GetMethod($path)), $variables) === false) { throw new Exception('File exists, but class is undefined for route: ' . $this->GetClass($path) . '->' . $this->GetMethod($path)); } return true; } return $this->Route('404'); } }
public function Main() { Layout::Get()->Display('404.tpl'); }