routes.php 1.0 KB

12345678910111213141516171819202122232425262728
  1. <?php
  2. /**
  3. * Lithium: the most rad php framework
  4. *
  5. * @copyright Copyright 2013, Union of RAD (http://union-of-rad.org)
  6. * @license http://opensource.org/licenses/bsd-license.php The BSD License
  7. */
  8. /**
  9. * The routes file is where you define your URL structure, which is an important part of the
  10. * [information architecture](http://en.wikipedia.org/wiki/Information_architecture) of your
  11. * application. Here, you can use _routes_ to match up URL pattern strings to a set of parameters,
  12. * usually including a controller and action to dispatch matching requests to. For more information,
  13. * see the `Router` and `Route` classes.
  14. *
  15. * @see lithium\net\http\Router
  16. * @see lithium\net\http\Route
  17. */
  18. use lithium\net\http\Router;
  19. use lithium\core\Environment;
  20. Router::connect('/json', 'Bench::json');
  21. Router::connect('/db/{:queries}', array('Bench::db', 'queries' => 1));
  22. Router::connect('/plaintext', 'Bench::plaintext');
  23. Router::connect('/update/{:queries}', array('Bench::update', 'queries' => 1));
  24. Router::connect('/fortunes', 'Bench::fortunes');
  25. ?>