CodeIgniter Forums
contact form issues - Printable Version

+- CodeIgniter Forums (
+-- Forum: Using CodeIgniter (
+--- Forum: General Help (
+--- Thread: contact form issues (/thread-70825.html)

contact form issues - Suhaib - 06-04-2018

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

RE: contact form issues - InsiteFX - 06-04-2018

PHP Code:
// for double quotes
$str str_replace('"'''$str);

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