public function GetRoute($uri = "")
	{
		$match = '';
		
		$qs = $uri ? $uri : (array_key_exists('QUERY_STRING', $_SERVER) ? $_SERVER['QUERY_STRING'] : '');
		$parsed = explode('&', $qs,2);
		$action = $parsed[0];
		
		if (strpos($action, '=') > -1 || !$action) {
			// the querystring is empty or the first param is a named param, which we ignore
			$match = $this->defaultAction;
		}
		else {
			// otherwise we have a route.  see if we have a match in the routemap, otherwise return the 'not found' route
			$method = RequestUtil::GetMethod();
			$route = $method.':'.$action;
			$match = array_key_exists($route, $this->routes) ? $this->routes[$route]['route'] : self::$ROUTE_NOT_FOUND;
		}
		
		return explode('.',$match,2);
	}
public function GetRoute($uri = "")
	{
		$match = '';
		
		$qs = $uri ? $uri : (array_key_exists('QUERY_STRING', $_SERVER) ? $_SERVER['QUERY_STRING'] : '');
		$parsed = explode('&', $qs,2);
		$action = $parsed[0];
		
		if (strpos($action, '=') > -1 || !$action) {
			// the querystring is empty or the first param is a named param, which we ignore
			$match = $this->defaultAction;
		}
		else {
			// otherwise we have a route.  see if we have a match in the routemap, otherwise return the 'not found' route
			$method = RequestUtil::GetMethod();
			$route = $method.':'.$action;
			$match = array_key_exists($route, $this->routes) ? $this->routes[$route]['route'] : self::$ROUTE_NOT_FOUND;
		}
		
		return explode('.',$match,2);
	}
public function GetRoute ( $ uri = "" ) { $ match = '' ; $ qs = $ uri ? $ uri : ( array_key_exists ( 'QUERY_STRING' , $ _SERVER ) ? $ _SERVER [ 'QUERY_STRING' ] : '' ) ; $ parsed = explode ( '&' , $ qs , 2 ) ; $ action = $ parsed [ 0 ] ; if ( strpos ( $ action , '=' ) > - 1 || ! $ action ) { // the querystring is empty or the first param is a named param, which we ignore $ match = $ this -> defaultAction ; } else { // otherwise we have a route.  see if we have a match in the routemap, otherwise return the 'not found' route $ method = RequestUtil :: GetMethod ( ) ; $ route = $ method . ':' . $ action ; $ match = array_key_exists ( $ route , $ this -> routes ) ? $ this -> routes [ $ route ] [ 'route' ] : self :: $ ROUTE_NOT_FOUND ; } return explode ( '.' , $ match , 2 ) ; }
Returns the controller and method for the given URI

@param string the url, if not provided will be obtained using the current URL
@return array($controller,$method)
Returns the controller and method for the given URI