| Current Path : /home/purehotels/public_html/components/com_purehotels/ |
| Current File : /home/purehotels/public_html/components/com_purehotels/router.php |
<?php
/**
* @package Joomla.Site
* @subpackage com_purehotels
*
* @copyright Copyright (C) 2005 - 2015 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
defined('_JEXEC') or die;
class PurehotelsRouter extends JComponentRouterBase
{
/**
* Build the route for the com_purehotels component
*
* @param array &$query An array of URL arguments
*
* @return array The URL arguments to use to assemble the subsequent URL.
*
* @since 3.3
*/
public function build(&$query)
{
return $segments;
}
public function parse(&$segments)
{
$vars = array();
switch($segments[0])
{
case 'booking':
if ($segments[0] != ':'){$vars['view'] = 'booking';}
break;
default:
die();
break;
}
$_GET = $vars;
return $vars;
}
}