|
@ -9,7 +9,7 @@ class Route extends \BaseController { |
|
|
'account' => false, |
|
|
'account' => false, |
|
|
'accountnext' => array('s', 'err'), |
|
|
'accountnext' => array('s', 'err'), |
|
|
'admin' => false, |
|
|
'admin' => false, |
|
|
'blog' => array('f'), |
|
|
|
|
|
|
|
|
'blog' => array('f', 'i'), |
|
|
'chat' => array('f'), |
|
|
'chat' => array('f'), |
|
|
'conf' => false, |
|
|
'conf' => false, |
|
|
'contact' => array('f'), |
|
|
'contact' => array('f'), |
|
@ -74,9 +74,9 @@ class Route extends \BaseController { |
|
|
return BASE_URI; |
|
|
return BASE_URI; |
|
|
|
|
|
|
|
|
if(isset($routes[$page])) { |
|
|
if(isset($routes[$page])) { |
|
|
if($params != false && count($routes[$page]) != count($params)) { |
|
|
|
|
|
throw new Exception(__('error.route', $page)); |
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
|
//if($params != false && count($routes[$page]) != count($params)) {
|
|
|
|
|
|
//throw new Exception(__('error.route', $page));
|
|
|
|
|
|
//} else {
|
|
|
if($tab != false) |
|
|
if($tab != false) |
|
|
$tab = '#'.$tab; |
|
|
$tab = '#'.$tab; |
|
|
//We construct a classic URL if the rewriting is disabled
|
|
|
//We construct a classic URL if the rewriting is disabled
|
|
@ -103,7 +103,7 @@ class Route extends \BaseController { |
|
|
$uri .= '/'.$params; |
|
|
$uri .= '/'.$params; |
|
|
} |
|
|
} |
|
|
return $uri.$tab; |
|
|
return $uri.$tab; |
|
|
} |
|
|
|
|
|
|
|
|
//}
|
|
|
} else { |
|
|
} else { |
|
|
throw new Exception(__('Route not set for the page %s', $page)); |
|
|
throw new Exception(__('Route not set for the page %s', $page)); |
|
|
} |
|
|
} |
|
|