Download the PHP package phpalchemy/routing without Composer
On this page you can find all versions of the php package phpalchemy/routing. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download phpalchemy/routing
More information about phpalchemy/routing
Files in phpalchemy/routing
Download phpalchemy/routing
More information about phpalchemy/routing
Files in phpalchemy/routing
Vendor phpalchemy
Package routing
Short Description PHP Alchemy Routing Component
License MIT
Homepage http://phpalchemy.org
Package routing
Short Description PHP Alchemy Routing Component
License MIT
Homepage http://phpalchemy.org
Keywords php routing
Please rate this library. Is it a good library?
Informations about the package routing
README
Faster & simple Http Routing
This is a Simple but faster URL Http routing library
Sample Use:
use Alchemy\Component\Routing\Mapper;
use Alchemy\Component\Routing\Route;
$mapper = new Mapper();
$mapper->connect(
'home_route',
new Route(
'/',
array(
'_controller' => 'sample',
'_action' => 'index'
)
)
);
$mapper->connect(
'to_index_route',
new Route(
'/{_controller}',
array('_action' => 'index')
)
);
$mapper->connect(
'complete_route',
new Route(
'/{_controller}/{_action}'
)
);
$mapper->connect(
'complete_route',
new Route(
'/leap_year/{year}', // pattern
array( // defaults
'_controller' => 'Validator',
'_action' => 'leapYear'
),
array( // requeriments
'year' => '\d+',
'_method' => array('GET', 'POST')
)
)
);
print_r($mapper->match('/home/sample'));
Array
(
[_controller] => home,
[_action] => sample
)
print_r($mapper->match('/leap_year/2012'));
Array
(
[_controller] => Validator,
[_action] => leapYear,
[year] => 2012,
)
All versions of routing with dependencies
PHP Build Version
Package Version
Requires
php Version
>=5.3.3
The package phpalchemy/routing contains the following files
Loading the files please wait ....