FOSUserBundle,法语翻译被忽略 [英] FOSUserBundle , French translation is ignored
问题描述
我是symfony的新用户,我目前正在学习课程(全日制),我的问题是:
I am a new user of symfony I currently following a course( full time), My problem :
# app/config/config.yml
framework:
translator: { fallback: %locale% }
app/config/parameters.ini:我设置了法语traduction(fr):
app/config/parameters.ini: I set up the French traduction(fr):
; These parameters can be imported into other config files
; by enclosing the key with % (like %database_user%)
; Comments start with ';', as in php.ini
[parameters]
database_driver = pdo_mysql
database_host = localhost
database_port =
database_name = blog
database_user = root
database_password =
mailer_transport = smtp
mailer_host = localhost
mailer_user =
mailer_password =
locale = fr
secret = ThisTokenIsNotSoSecretChangeIt
但是标签表单注册/登录仍然是英文...
我使用版本FriendsOfSymfony-FOSUserBundle-1.2.0-0
,因为最新版本FriendsOfSymfony-FOSUserBundle-1.2.0-57-g72e8023
but labels forms register / login, is still in English...
I use version FriendsOfSymfony-FOSUserBundle-1.2.0-0
, because of bug under the latest FriendsOfSymfony-FOSUserBundle-1.2.0-57-g72e8023
请帮忙吗?
推荐答案
在编辑了文件parameters.ini之后,有必要:
After editing the file parameters.ini, it is necessary to:
- 断开连接(如果已登录)
- 重新连接
- ...
- 重新加载 页面(/登录),如果它不起作用,则清除缓存并重新加载
- disconnect(if you been logged)
- reconnect
- ...
- reload the page(/login) if it does not work, then clear the Cache and reload
如果您打算自定义翻译的语言,则可以复制/粘贴
vendor\bundles\FOS\UserBundle\Resources\translations
在您自己的捆绑软件中src\Mysite\UserBundle\Resources\translations
或在app\Resources
下(请勿修改原始说明!).
if you plan to customize the translated language , you may to copy/paste the
vendor\bundles\FOS\UserBundle\Resources\translations
in your own Bundle src\Mysite\UserBundle\Resources\translations
Or under app\Resources
(don't modify the original traduction!).
这篇关于FOSUserBundle,法语翻译被忽略的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!