CodeIgniter Forums

Full Version: contact form issues
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
hello all 

I have a website made by CI, inside the site there's a contact form deployed in this way 

from the admin, we enter the e-mail that receives the messages from visitors 

the visitor when going to contact form he fills the form and enters his email address 

the site will forward this message using phpmail() to the receiver email and put the visitor email in the field of replay to 

so the person who will receive the message can directly click on replay and the replay will send to the visitor 

the problem is the visitor email address inserted into the message between ' ' so the receiver can't reply to it 
(attached photo)

also, I have another issue 

if you see library I have 3 ways to send the message (PHPMAIL, GMAIL, and SMTP) and the configuration of last two options from admin panel now only phpmail working but when I make it SMTP or Gmail not work be know that the information is correct 

MVC files and library attached
PHP Code:
// for double quotes
$str str_replace('"'''$str);

// for single quotes
$str str_replace("'"""$str);