Welcome Guest, Not a member yet? Register   Sign In
Anyone can help PLEASE in the code of PHP send e-mail i have tried everything but when don´t receive any e-mail i believ
#1

[eluser]IronAngel[/eluser]
Hello below i paste the PHP send i need help because i don´t know were i do wrong:

<?PHP

if (!get_magic_quotes_gpc()) {
foreach($_POST as $key=>$value) {
$temp = addslashes($value);
$_POST[$key] = $temp;
}
}

// ADD YOUR EMAIL HERE //
$to = '[email protected]';
// VARIABLE NAME FROM FLASH //
$name = 'Name: '.$_POST['name'];
// VARIABLE EMAIL FROM FLASH //
$email = 'Email: '.$_POST['email'];
// VARIABLE TELEPHONE NUMBER FROM FLASH //
$telephone = 'Telephone Number: '.$_POST['telephone'];$subject ='ZERO Y CONCTACT FORM:'.$_POST['subject'];
// VARIABLE MESSGAE FROM FLASH //
$message = $_POST['message'];
$additionalHeaders = "From: [email protected]\n";
$additionalHeaders .= "Reply-To: ".$_POST['name']."<".$_POST['email'].">\n";
// RECEIVED MESSAGE FROM WHICH YOU CAN CHANGE TO YOUR OWN //
$messagetosend = 'You have recieved an email via your website from:'."\n\n";
$messagetosend .= $name."\n";
$messagetosend .= $email."\n";
$messagetosend .= $telephone."\n\n";
$messagetosend .= 'Here is the message:'."\n\n";
$messagetosend .= $message."\n\n";
/// REPLY MESSAGE WHICH YOU CAN CHANGE TO YOUR OWN //
$messagetosend .= 'You can reply to this mesage to respond'."\n\n";


$OK = mail($to, $subject, stripslashes($messagetosend), $additionalHeaders);
//
if ($OK) {
$flashreply = 'Email Message Sent';
echo 'sentSuccess='.urlencode($flashreply);
} else {
}

?&gt;
#2

[eluser]InsiteFX[/eluser]
This is not CodeIgniter Code!
#3

[eluser]IronAngel[/eluser]
Sorry, first i have put the e-mail address in the php, didn´t work, second i have changed these codes:

$additionalHeaders = "From: [email protected]\n";
$additionalHeaders .= "Reply-To: ".$_POST['name']."<".$_POST['email'].">\n";

Don´t work i click the button send give the response that tha e-mail was sent sucessefuly i check the e-mail i don´t receive anything.

I don´t know what i can do to make it work, i need help someone to give me the right direction and help me to solve this problem.

Thank you.
#4

[eluser]IronAngel[/eluser]
I have put the my question i believe in the right place, sorry for my mistake.
#5

[eluser]InsiteFX[/eluser]
Well if your using codeIgniter then use the Email Class!
#6

[eluser]johnpeace[/eluser]
http://ellislab.com/codeigniter/user-gui...email.html
#7

[eluser]IronAngel[/eluser]
Thank you InsiteFX and Johnpeace for your prompt reply.
Can you explain to me how i can make the changes to make the e-mail working and receiving i will be very thank full to all of you.
I can make most anything but in the PHP i´m a zero.
#8

[eluser]InsiteFX[/eluser]
CodeIgniter User Guide - Email Class




Theme © iAndrew 2016 - Forum software by © MyBB