// handle img extensions in the end of query string in the dispatcher
This commit is contained in:
1 parent
970449148c
commit
78a6821b2f
1 file changed
+1
-1
@@ -716,7 +716,7 @@ class DispatcherCore
|
|||||||
$controller = $this->controller_not_found;
|
$controller = $this->controller_not_found;
|
||||||
|
|
||||||
// If the request_uri matches a static file, then there is no need to check the routes, we keep "controller_not_found" (a static file should not go through the dispatcher)
|
// If the request_uri matches a static file, then there is no need to check the routes, we keep "controller_not_found" (a static file should not go through the dispatcher)
|
||||||
if (!preg_match('/\.(gif|jpe?g|png|css|js|ico)$/i', $this->request_uri))
|
if (!preg_match('/\.(gif|jpe?g|png|css|js|ico)$/i', parse_url($this->request_uri, PHP_URL_PATH)))
|
||||||
{
|
{
|
||||||
// Add empty route as last route to prevent this greedy regexp to match request uri before right time
|
// Add empty route as last route to prevent this greedy regexp to match request uri before right time
|
||||||
if ($this->empty_route)
|
if ($this->empty_route)
|
||||||
|
|||||||
Reference in new issue
Block a user