Har*_*rup 4 php symfony1 sfguard
我在我的项目中使用Symfony 1.4和ORM作为Propel.我已经配置了Settings.yml来保护我的页面.但是我可以通过扩展所有functionality.i发现一个文章中的SfGuard插件我的行动使自定义登录/注销SymfonyLab,但还不够清楚.
覆盖sfGuard登录视图的最简单方法:
1)在前端模块中创建一个名为'sfGuardAuth'的目录:
mkdir apps/frontend/modules/sfGuardAuth
mkdir apps/frontend/modules/sfGuardAuth/templates
Run Code Online (Sandbox Code Playgroud)
2)将默认模板从sfGuardPlugin文件夹复制到新模块
cp plugins/sfGuardPlugin/modules/sfGuardAuth/templates/* apps/frontend/modules/sfGuardAuth/templates
Run Code Online (Sandbox Code Playgroud)
3)将新文件编辑为您的内容
4)清除缓存
./symfony cc
Run Code Online (Sandbox Code Playgroud)