sending mail in html |
I try different code but none works with me I am using CI4
PHP Code: $email = \Config\Services::email(); I got an error on $email->mailType('html'); I tried $email->set_mailtype("html"); same I tried PHP Code: $config['mailtype'] = 'html'; No error but I receive the html code as text How is the correct way of sending html mail
Change this:
PHP Code: $email->mailType('html'); to this PHP Code: $email->setMailType('html'); Or Change this: PHP Code: $config['mailtype'] = 'html'; to thisĀ (case sensitive!) PHP Code: $config['mailType'] = 'html';
Thank you! It works That would be nice to have an example in the documentation. I didn't find it.
|
Welcome Guest, Not a member yet? Register Sign In |