mirror of
https://github.com/skipperbent/simple-php-router.git
synced 2026-06-17 08:47:52 +00:00
Merge pull request #28 from skipperbent/development
[BUGFIX] Fixed routeMatch in RouterEntry not matching routes with multiple arguments.
This commit is contained in:
@@ -44,7 +44,7 @@ class RouterRoute extends RouterEntry {
|
|||||||
|
|
||||||
$route = $this->url;
|
$route = $this->url;
|
||||||
|
|
||||||
$routeMatch = preg_replace('/'.self::PARAMETERS_REGEX_MATCH.'/is', '', $route);
|
$routeMatch = preg_replace('/\/{0,1}'.self::PARAMETERS_REGEX_MATCH.'\/{0,1}/is', '', $route);
|
||||||
|
|
||||||
// Check if url parameter count matches
|
// Check if url parameter count matches
|
||||||
if(stripos($url, $routeMatch) === 0) {
|
if(stripos($url, $routeMatch) === 0) {
|
||||||
|
|||||||
Reference in New Issue
Block a user