I read up on two ways to override the FOSUser login form:
However, with Symfony Flex the project structure changed substantially.
As for option #1: There is no app/Resources
folder anymore. I store my templates in /templates
.
Regarding option #2: There is no AppBundle anymore.
Now, I extended FOSUser's security Controller:
<?php
namespace App\Controller;
use FOS\UserBundle\Controller\SecurityController as BaseController;
class SecurityController extends BaseController
{
public function renderLogin(array $data)
{
return $this->render('/Admin/Login/index.html', $data);
}
}
The application still renders the FOSUserBundle form. I have a feeling that I have to register the avobe controller somehow. In the FOSUser config, there is no directive for that. How can this be achieved?