Jump to content

More problems with Mail ()


fazlionline

Recommended Posts

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?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...