[eluser]Unknown[/eluser]
I a fairly new to codeigniter and php, and this may be an obvious question, but I need some help in using variables in the codeigniter email class.
I have a simple automated email response set up in a controller using this code:
$this->email->from('$my_email', '$my_name');
$this->email->to($contact_email);
$this->email->subject('Automate response');
$this->email->message('Thank you for your email, we will get back to you shortly');
$this->email->send();
My question is this: How do I use variables within the text of the "message" field? For example, I would like to be able to do something like:
$this->email->message('Dear $contact_name, Thank you for your email, we will get back to you shortly');
Like I said, I imagine that this is a fairly basic question, but I really appreciate any help you can give me!