Symfony2.1: Unable to find the controller for path "/login_check"
Tag : php , By : Yohan Lee
Date : March 29 2020, 07:55 AM
I hope this helps . I found the solution to my problem I added the /backend prefix to my paths, removed the 'anonymous: ~' line and commented out the ACL for backend. firewalls:
dev:
pattern: ^/(_(profiler|wdt)|css|images|js)/
security: false
login_firewall:
pattern: ^/backend/login$
anonymous: ~
backend:
pattern: ^/backend
form_login:
provider: entity
login_path: /backend/login
check_path: /backend/login_check
#use_forward: true
logout:
path: /backend/logout
target: /
access_control:
#- { path: ^/backend, roles: ROLE_USER }
login:
pattern: /backend/login
defaults: { _controller: VitaSecurityBundle:Default:login }
login_check:
pattern: /backend/login_check
logout:
pattern: /backend/logout
|
Unable to find the controller for path "/login_check" - no matching controller found
Date : March 29 2020, 07:55 AM
wish of those help It's crazy. There was no error with Symfony. I'm using Jquerymobile 1.3.1 for the frontend and after every login the url in the browser points to http://myapp.localhost/app_dev.php/login_check. I got the right content after login, but when viewing sourcecode I see the error: Unable to find the controller for path “/login_check”. And when I use the browser refresh button I see the classic symfony 2 failure site. When I remove all the jquerymobile js and css, the login system works as expected. Maybe I need to change the login form from post to some kind of ajax submitting.
|
Unable to find the controller for path "/login_check" in symfony 2
Date : March 29 2020, 07:55 AM
I wish did fix the issue. Follow the instructions closely on the symfony docs for Using a Login Form. If you follow these instructions, you shouldn't have any issues with your login_check.
|
Unable to find the controller for path "/login_check" - symfony2
Date : March 29 2020, 07:55 AM
Hope that helps The route login_check is not behind the firewall because the login_check route pattern matches the login firewall which has no security. login:
pattern: ^/login # This matches /login_check
security: false
login:
pattern: ^/login$
security: false
access_control:
- { path: ^/login$, role: IS_AUTHENTICATED_ANONYMOUSLY }
|
Symfony2: Unable to find the controller for path "/en/login_check"
Date : March 29 2020, 07:55 AM
|