Bonsoir à tous ,
je me permets de poster un message car je bloque sur la configuration de Symfony...
J'ai configuré l'email et j'arrive à en envoyer depuis la console en faisant
Je reçois bien le mail que j'envoie .
Code : Sélectionner tout - Visualiser dans une fenêtre à part $php bin/console swiftmailer:email:send
Cependant je n'arrive pas a faire en sorte que mon UserBundle héritant de FOSUserBundle en envoie .
Il y à marqué que le mail est envoyé mais je n'en reçoit aucun , j'ai bien verifié mon dossier spam il est vide aussi.
J'aurais donc besoin de votre aide , s'il vous plaît !
Voici mes different fichiers de configuration :
mon app/config.yml
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100 imports: - { resource: parameters.yml } - { resource: security.yml } - { resource: services.yml } - { resource: "@CouchsurfBundle/Resources/config/services.yml" } # Put parameters here that don't need to change on each machine where the app is deployed # http://symfony.com/doc/current/best_practices/configuration.html#application-related-configuration parameters: locale: en framework: #esi: ~ translator: { fallbacks: ["%locale%"] } secret: "%secret%" router: resource: "%kernel.root_dir%/config/routing.yml" strict_requirements: ~ form: ~ csrf_protection: ~ validation: { enable_annotations: true } #serializer: { enable_annotations: true } templating: engines: ['twig'] default_locale: "%locale%" trusted_hosts: ~ trusted_proxies: ~ session: # http://symfony.com/doc/current/reference/configuration/framework.html#handler-id handler_id: session.handler.native_file save_path: "%kernel.root_dir%/../var/sessions/%kernel.environment%" fragments: ~ http_method_override: true assets: ~ # Twig Configuration twig: debug: "%kernel.debug%" strict_variables: "%kernel.debug%" # Doctrine Configuration doctrine: dbal: driver: pdo_mysql host: "%database_host%" port: "%database_port%" dbname: "%database_name%" user: "%database_user%" password: "%database_password%" charset: UTF8 # if using pdo_sqlite as your database driver: # 1. add the path in parameters.yml # e.g. database_path: "%kernel.root_dir%/data/data.db3" # 2. Uncomment database_path in parameters.yml.dist # 3. Uncomment next line: # path: "%database_path%" orm: auto_generate_proxy_classes: "%kernel.debug%" naming_strategy: doctrine.orm.naming_strategy.underscore auto_mapping: true # Swiftmailer Configuration swiftmailer: transport: "%mailer_transport%" host: "%mailer_host%" username: "%mailer_user%" password: "%mailer_password%" port: 587 auth_mode : login encryption: tls spool: { type: memory } fos_user: db_driver: orm firewall_name: main user_class: UserBundle\Entity\User registration: confirmation: enabled: true from_email: address: adresseEmail@gmail.com sender_name: CouchSurf service: mailer: fos_user.mailer.default email_canonicalizer: fos_user.util.canonicalizer.default token_generator: fos_user.util.token_generator.default username_canonicalizer: fos_user.util.canonicalizer.default user_manager: fos_user.user_manager.default assetic: debug: '%kernel.debug%' use_controller: '%kernel.debug%' filters: cssrewrite: ~ # ...
config_dev.yml :
parameters.yml
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31 imports: - { resource: config.yml } framework: router: resource: "%kernel.root_dir%/config/routing_dev.yml" strict_requirements: true profiler: { only_exceptions: false } web_profiler: toolbar: true intercept_redirects: true # the default value is false replace it with true in order to enable the profiler debugger monolog: handlers: main: type: stream path: "%kernel.logs_dir%/%kernel.environment%.log" level: debug channels: [!event] console: type: console channels: [!event, !doctrine] # uncomment to get logging in your browser # you may have to allow bigger header sizes in your Web server configuration #firephp: # type: firephp # level: info #chromephp: # type: chromephp # level: info
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12 # This file is auto-generated during the composer install parameters: database_host: 127.0.0.1 database_port: null database_name: surfcouch database_user: root database_password: dahlia mailer_transport: smtp mailer_host: smtp.gmail.com mailer_user: adresse@gmail.com mailer_password: monpassword secret: 3d096e67f634afe14a3c7ca3f9721970d8ca52fa
Partager