PHPackages                             project-a/silex-routing - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Framework](/categories/framework)
4. /
5. project-a/silex-routing

AbandonedArchivedLibrary[Framework](/categories/framework)

project-a/silex-routing
=======================

Silex-Routing provides advanced routing for Silex through connecting symfony-cmf/Routing with Silex.

v2.0.1(8y ago)121.5k1MITPHPPHP &gt;=5.5.9

Since Sep 12Pushed 8y ago1 watchersCompare

[ Source](https://github.com/chili-labs/Silex-Routing)[ Packagist](https://packagist.org/packages/project-a/silex-routing)[ RSS](/packages/project-a-silex-routing/feed)WikiDiscussions master Synced 3w ago

READMEChangelog (9)Dependencies (4)Versions (11)Used By (0)

Silex-Routing
=============

[](#silex-routing)

###### Serviceprovider for advanced and dynamic routing in Silex

[](#serviceprovider-for-advanced-and-dynamic-routing-in-silex)

[![Latest Stable Version](https://camo.githubusercontent.com/5c8522fb219005a2e053dc622ec34daf563e8e10fbdcf701ba51145b500a2d36/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f70726f6a6563742d612f73696c65782d726f7574696e672e7376673f7374796c653d666c6174266c6162656c3d737461626c65)](https://packagist.org/packages/project-a/silex-routing)[![Total Downloads](https://camo.githubusercontent.com/ddf7df4bc9daac453a7949770ec21206f281063c598b6a9513d7e26cbfc1c513/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f70726f6a6563742d612f73696c65782d726f7574696e672e7376673f7374796c653d666c6174)](https://packagist.org/packages/project-a/silex-routing)[![License](https://camo.githubusercontent.com/f9cefda7e892d3be10202379eb3f457f0f1c15a7138fa2be21964a219c057ead/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f70726f6a6563742d612f73696c65782d726f7574696e672e7376673f7374796c653d666c6174)](https://packagist.org/packages/project-a/silex-routing)[![Build Status](https://camo.githubusercontent.com/007a93d7dc3d27287e6b99f83d032ca99ae69ca317f5340fc1c4d04c7b985dc9/68747470733a2f2f7365637572652e7472617669732d63692e6f72672f6368696c692d6c6162732f53696c65782d526f7574696e672e7376673f6272616e63683d6d6173746572)](http://travis-ci.org/chili-labs/Silex-Routing)[![Coverage Status](https://camo.githubusercontent.com/14c0947527839e1456620fe4eba1b7aa1425689faf498b87f5c948bb155482b3/68747470733a2f2f696d672e736869656c64732e696f2f636f766572616c6c732f6368696c692d6c6162732f53696c65782d526f7574696e672f6d61737465722e7376673f7374796c653d666c6174)](https://coveralls.io/r/chili-labs/Silex-Routing?branch=master)[![SensioLabsInsight](https://camo.githubusercontent.com/9a470c055bbaa64b1038dcd0de9a99a5e22f3e113e6a6a5bd22c777d6e57542f/68747470733a2f2f696e73696768742e73656e73696f6c6162732e636f6d2f70726f6a656374732f35616164363238392d666438642d346461632d393437322d6662303234323861396630612f6d696e692e706e67)](https://insight.sensiolabs.com/projects/5aad6289-fd8d-4dac-9472-fb02428a9f0a)

Description
-----------

[](#description)

Silex-Routing allows you to define custom and multiple routers for Silex. This is especially useful when working with dynamic routes, which are not known while writing the code (e.g. URLs stored in database).

This implementation works for both, matching and generating of URLs.

The advanced routing is achieved by connecting Silex with symfony-cmf/Routing.

Installation
------------

[](#installation)

The recommended way to install Silex-Routing is [through composer](http://getcomposer.org). Just create a `composer.json` file and run the `php composer.phar install` command to install it:

```
{
    "require": {
        "project-a/silex-routing": "dev-master"
    }
}

```

Alternatively, you can download the [`silexrouting.zip`](https://github.com/chili-labs/Silex-Routing/archive/master.zip) file and extract it.

#### Upgrade from 1.0 to 2.0

[](#upgrade-from-10-to-20)

Version 2 is not backward compatible with version 1. Make sure to carefully read the [changelog](https://github.com/chili-labs/Silex-Routing/blob/master/CHANGELOG.md).

Usage
-----

[](#usage)

Using Silex-Routing is very simple. All you need to do is register the provided `RoutingServiceProvider` and afterwards add all your custom routers (`RouterInterface`).

```
$app = new \Silex\Application();
$app->register(new \ChiliLabs\Silex\Provider\RoutingServiceProvider());

$router2 = new \Acme\Silex\MySpecialRouter();
$app['routers']->add($router);
...
```

There is a router in this repository named `SilexRouter`, that handles the default routing behavior of Silex. Registering this router ensures, that all routes added through the main Silex application still work. (This router is not registered by default.)

*Since version 2.0 of project-a/silex-routing the url generation is included in the `RoutingServiceProvider` and no special `UrlGeneratorServiceProvider` is needed anymore.*

Tests
-----

[](#tests)

To run the test suite, you need [composer](http://getcomposer.org).

```
$ php composer.phar install --dev
$ phpunit

```

License
-------

[](#license)

Silex-Routing is licensed under the MIT license.

###  Health Score

33

—

LowBetter than 72% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity23

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity64

Established project with proven stability

 Bus Factor1

Top contributor holds 99.2% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~161 days

Recently: every ~255 days

Total

10

Last Release

3212d ago

Major Versions

1.0.x-dev → v2.0.02016-06-06

### Community

Maintainers

![](https://www.gravatar.com/avatar/a7cde42b54238fd17408f85319094d265add1ac23c2ac2b5a171cafd34e20496?d=identicon)[danez](/maintainers/danez)

---

Top Contributors

[![danez](https://avatars.githubusercontent.com/u/231804?v=4)](https://github.com/danez "danez (118 commits)")[![bitdeli-chef](https://avatars.githubusercontent.com/u/3092978?v=4)](https://github.com/bitdeli-chef "bitdeli-chef (1 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/project-a-silex-routing/health.svg)

```
[![Health](https://phpackages.com/badges/project-a-silex-routing/health.svg)](https://phpackages.com/packages/project-a-silex-routing)
```

###  Alternatives

[laravel/framework

The Laravel Framework.

34.8k532.1M19.4k](/packages/laravel-framework)[symfony/framework-bundle

Provides a tight integration between Symfony components and the Symfony full-stack framework

3.6k246.0M11.1k](/packages/symfony-framework-bundle)[sulu/sulu

Core framework that implements the functionality of the Sulu content management system

1.3k1.4M196](/packages/sulu-sulu)[pimcore/pimcore

Content &amp; Product Management Framework (CMS/PIM/E-Commerce)

3.8k3.8M462](/packages/pimcore-pimcore)[drupal/core

Drupal is an open source content management platform powering millions of websites and applications.

19564.8M1.6k](/packages/drupal-core)[shopware/platform

The Shopware e-commerce core

3.4k1.5M3](/packages/shopware-platform)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
