用户注册后,FOSUserBundle 2.0没有确认电子邮件

时间:2017-09-06 14:26:02

标签: symfony fosuserbundle

我使用Symfony 3.3和FOSUserBundle 2.0并重写了RegistrationControler以使用我自己的用户规范,但注册过程没有任何不同。

当我设置为启用确认时,没有发送电子邮件但正在处理重置密码!

这是我的config.yml:

# FOSUserBundle
fos_user:
    db_driver: orm # other valid values are 'mongodb' and 'couchdb'
    firewall_name: main
    user_class: AppBundle\Entity\User
    from_email:
        address: "%mailer_user%"
        sender_name: "%mailer_user%"
    registration:
            form:
                type: AppBundle\Form\RegistrationType
            confirmation:
                enabled: true
    profile:
            form:
                type: AppBundle\Form\ProfileType

不确定发生了什么,有人可以帮忙吗?

1 个答案:

答案 0 :(得分:0)

<\ n>在yml文件中,不允许使用制表符,只需要使用空格。而且我确定你过多地缩进了你的“形式”行。

registration:
    form:
        type: AppBundle\Form\RegistrationType
    confirmation:
        enabled: true
profile:
    form:
        type: AppBundle\Form\ProfileType
相关问题