Topic: More problems with Mail ()
More problems with Mail ()
I have a form with some fields on my client site.
For the time being, I used my own email, if the user check the form and fill it, all the email data comes to my inbox.
But I received some marketing emails in my inbox and used the email address of that site.
my code is:
<?php
$to = "123@yahoo.com";
$url = "ACD - Contact Form";
$subject = $_REQUEST['subj'] ;
$org = $_REQUEST['org'] ;
$tele = $_REQUEST['tele'] ;
$city = $_REQUEST['city'] ;
$email = $_REQUEST['email'] ;
$message = $_REQUEST['message'] ;
$details = "URL - Form : $url\n
Subject: $subject\n
Organization: $org\n
Telephone: $tele\n
City: $city\n
From: $email \n
Message: $message \n
";
$headers = "From: $email";
$sent = mail($to, $subject, $details, $headers, $message) ;
if($sent)
{print "Your mail was sent successfully"; }
else
{print "We encountered an error sending your mail"; }
?> How can I get rid of it?

