New in Horde: Routes
-
I’m pleased to announce the first release of Horde/Routes, a new URL mapping system for PHP 5. This package provides classes for mapping URLs into the controllers and actions of an MVC system, inspired by Ruby on Rails.
There are already quite a few existing libraries that do this sort of thing for PHP. Horde/Routes is a compelling alternative.
At Maintainable, we examined most of these PHP solutions and found them all inadequate for various reasons, particularly because we wanted RESTful routing, named routes, sophisticated matching, PHP 5 E_STRICT, and extensive test coverage.
Since we do quite a bit of Ruby and Python programming, we surveyed the options in those languages and decided to do a full port of the Python library, Routes.
Horde/Routes provides these features and more:
- Supports route recognition and generation
- Sophisticated matching conditions like subdomains
- Named routes and RESTful route generation
- PEAR-style naming and coding standards
- PHP 5 E_STRICT compliant, web framework agnostic
- A comprehensive unit test suite
Maintainable decided to contribute the code to Horde’s Rampage project because Horde is one of PHP’s oldest and most successful projects. We’re using and contributing to other Horde libraries and we think Rampage is worth your attention.
The Python version has been around for some time and is very popular with different Python web frameworks. We’re happy to be part of that ecosystem now and our full port has already resulted in patches being committed back to the Python version.
At Maintainable, we’ve already used Horde_Routes on several applications. While Horde/Routes is relatively new, it is very feature-rich and well-tested.
Currently, Horde/Routes is a beta release. Over the coming weeks, we’ll be making some minor changes to the API and adding more documentation, and then it will quickly move to stable.
Update: The project now has its own pages on the Horde website and was featured on Chuck Hagenbuch’s blog.

3 comments
comment by Alex @ Net 16 Sep 07
It would be great to compare the Horde_Routes with Zend Framework routes. Are they have similar concepts behind them and (what I hope) have similar API?
Thanks,
Alex
comment by Khaoz 8 Oct 07
Ty for this man. Waiting for an stable release:)
comment by rodrigo moraes 30 Oct 07
Amazing! Once I thought to port Routes, and I love to see that there is a PHP version now. Looks very nice, congrats. :)
Post a comment