简体   繁体   中英

FOSUserBundle 2.0 no confirmation email after user registration

I'm using Symfony 3.3 and FOSUserBundle 2.0 and have overridden RegistrationControler to use my own User specification, but nothing different on the registration process.

When I set true to confirmation enabled no email is sent but working on reset password!

Here is my 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

Not sure what is happening, can someone help?

in yml files, tabs are not allowed, you need to use spaces only. And i'm sure you indent your "form" line too much.

registration:
    form:
        type: AppBundle\Form\RegistrationType
    confirmation:
        enabled: true
profile:
    form:
        type: AppBundle\Form\ProfileType

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM