Download the PHP package simonhamp/routes without Composer

On this page you can find all versions of the php package simonhamp/routes. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package routes

Routes

Hi, thanks for checking out Routes! Routes is low-level PHP class for defining and using URL routing patterns similar to CodeIgniter. In fact Routes is based on CodeIgniter's implementation.

Installation

Install via Composer from your command line:

Usage

To use Routes, you simply need to place the class somewhere accessible within your application. Then you need to define some routes and register them:

Why?

In-App Routing, as opposed to URL Rewriting (e.g. .htaccess/mod_rewrite), is a popular method for defining patterns for URLs in web sites and applications. It allows the developer to make an app appear one way, but underneath go another. It's most commonly found in MVC web frameworks (Rails, Sinatra, CakePHP, CodeIgniter et al). Routing is simple, but powerful, and the concept is also really useful in other situations outside the context of a framework.

There are other attempts at portable routing libraries, but they're too tied into the MVC framework schema to be useful outside. That's where Routes comes in. You could use it as your routing system for yet another framework or you can keep it completely separate.

Using Routes you can define complex routes using simple instructions and get the rewritten URL as a return variable in your code. So it doesn't need a specific web server. It doesn't do anything fancy, it just rewrites the URLs you give it according to the rules you supply, in the order you supplied them. Simple.

Hope you find it useful! :)

Questions? Comments? Feel free to raise an issue

But I want a real router!

Then may I suggest the awesome FastRoute by @nikic. It's really fast, has some awesome features, and includes a dispatcher that will pass the various parts of your routes to a method you define.


All versions of routes with dependencies

PHP Build Version
Package Version
Requires php Version >=5.3.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package simonhamp/routes contains the following files

Loading the files please wait ....