+ initial work towards a new tdo/doa abstraction on the database level
[vsc.git] / _res / _libs / urlhelpers / tsurlfancy.class.php
blob94c044b86e14ce92a57f7662a8df4d1e49ba8a01
1 <?php
2 /**
3 * @desc Object to handle fancy friendly url requests
6 * @author Marius Orcsik <marius@habarnam.ro>
7 * @package url helpers
8 * @license GPL
9 */
10 class tsUrlFancy extends tsUrlFriendly {
11 private $routes = array ();
13 public function addRoutes ($regexRoutes = array()) {
14 if (!is_array($regexRoutes) || sizeof ($regexRoutes) == 0)
15 return false;
16 $this->routes = $regexRoutes;
19 /**
20 * uses the regex for $controller controller to replace the subpatterns
21 * with array members
23 * the output is passed to the parent::setRequest method
24 * @see _res/_libs/urlhelpers/tsUrlFriendly#setRequest()
26 public function setRequest ($array = array()) {
27 $controller = array_shift($array);
28 $action = array_shift($array);
30 var_dump($this);
31 return parent::setRequest ($array);