sending email via gmail |
I'm trying to send emails with gmail attachment but codeigniter always gives me the error:
to: 555 5.5.2 Syntax error. n2sm18426280wra.89 - gsmtp The following SMTP error was encountered: 555 5.5.2 Syntax error. n2sm18426280wra.89 - gsmtp in any case, however, the email arrives correctly at its destination! below is the code I use to send PHP Code: function sendEmail($to = '', $subject = '', $body = '', $attachment = '') { PHP Code: $config = array(); What did you Try? What did you Get? What did you Expect?
Joined CodeIgniter Community 2009. ( Skype: insitfx )
(05-02-2019, 06:46 AM)php_rocs Wrote: @emanuele.zamengo thanks in this way it works !!
(05-02-2019, 10:28 AM)php_rocs Wrote: @emanuele.zamengo I ask one last thing: if I manually set the recipient address in this way PHP Code: $ Controller-> Email-> to ('<[[email protected]>']test.test@gmail.com>'[/email]); everything works correctly if instead I compose it like this: PHP Code: $ Controller-> Email-> to ('<'. $ To. '>'); from error anyway! where's the problem?
@emanuele.zamengo,
Then this tells me that only the first solution works and maybe there was a change to what is acceptable by Google.
|
Welcome Guest, Not a member yet? Register Sign In |