PHPackages                             edom/simple-router-php - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. edom/simple-router-php

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

edom/simple-router-php
======================

Simple Router in PHP to use in small projects

067PHP

Since Apr 23Pushed 6y ago1 watchersCompare

[ Source](https://github.com/systemEDOM/simpleRouterPHP)[ Packagist](https://packagist.org/packages/edom/simple-router-php)[ RSS](/packages/edom-simple-router-php/feed)WikiDiscussions master Synced 3d ago

READMEChangelogDependenciesVersions (1)Used By (0)

SimpleRouterPHP
===============

[](#simplerouterphp)

---

.htaccess
---------

[](#htaccess)

```
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [L]
```

Start with package
------------------

[](#start-with-package)

```
require_once "../vendor/autoload.php";

use EDOM\SimpleRouterPHP\Router;

$router = new Router("EDOM\\");
```

**Router receive as parameter the namespace where you manage your controllers**

GET
---

[](#get)

```
$router->get('/', function () {
    echo "get";
});

$router->get('/users/[i:id]', 'UsersController@show');
```

POST
----

[](#post)

```
$router->post('/', function () {
    echo "post";
});

$router->post('/users/[i:id]', 'UsersController@store');
```

PUT
---

[](#put)

```
$router->put('/', function () {
    echo "put";
});

$router->put('/users/[i:id]', 'UsersController@update');
```

DELETE
------

[](#delete)

```
$router->delete('/', function () {
    echo "delete";
});

$router->delete('/users/[i:id]', 'UsersController@delete');
```

**The structure to pass a controller is Class@method**

Finally call this method
------------------------

[](#finally-call-this-method)

```
$router->match();
```

###  Health Score

19

—

LowBetter than 10% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity34

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% 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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/6041a8684788b458e6ef7cbf1f97cf66a19de1d53ca7d9431ab8b24b64a39d76?d=identicon)[systemEDOM](/maintainers/systemEDOM)

---

Top Contributors

[![systemEDOM](https://avatars.githubusercontent.com/u/10385109?v=4)](https://github.com/systemEDOM "systemEDOM (8 commits)")

### Embed Badge

![Health badge](/badges/edom-simple-router-php/health.svg)

```
[![Health](https://phpackages.com/badges/edom-simple-router-php/health.svg)](https://phpackages.com/packages/edom-simple-router-php)
```

###  Alternatives

[umpirsky/currency-list

List of all currencies with names and ISO 4217 codes in all languages and all data formats.

326325.2k10](/packages/umpirsky-currency-list)[fuel/parser

FuelPHP 1.x Parser Package

601.2M5](/packages/fuel-parser)

PHPackages © 2026

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