php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #64265 mail is send to spam by using mail function in php.........
Submitted: 2013-02-21 13:18 UTC Modified: 2013-10-15 11:54 UTC
Votes:1
Avg. Score:5.0 ± 0.0
Reproduced:0 of 0 (0.0%)
From: ramkumar at spiderindia dot com Assigned:
Status: No Feedback Package: PHPScript (PECL)
PHP Version: 5.4.11 OS: window7
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: ramkumar at spiderindia dot com
New email:
PHP Version: OS:

 

 [2013-02-21 13:18 UTC] ramkumar at spiderindia dot com
Description:
------------
---
From manual page: http://www.php.net/function.mail
---
<?php ob_start(); define("MONITORADDRESS","chelvi@spiderindia.com");?>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>email sending..</title>
</head>
<body>
<?php
if(isset($_REQUEST['email']))
{
 $msg ='<table border="0" style="font: 12px Arial, Helvetica, sans-serif; line-
height:20px; " width="350"  align="center" cellpadding="5" cellspacing="1">
	<tr><td colspan="2" align="center"  style="font: 18px Arial, Helvetica, 
sans-serif; color:#FFFFFF; background-color:#626D7F;">ONLINE ENQUIRY</td></tr>
 				<tr><td width="35%"  style="font-weight: bold; 
background-color:#D8DADF; padding-left:10px;" >Name :</td><td style="background-
color:#D8DADF; padding-left:10px;" width="65%" >'.$_REQUEST['name'].'</td></tr>
				<tr><td width="35%"  style="font-weight: bold; 
background-color:#D8DADF; padding-left:10px;" >Phone :</td><td 
style="background-color:#D8DADF; padding-left:10px;" width="65%" 
>'.$_REQUEST['phone'].'</td></tr>
				<tr><td width="35%"  style="font-weight: bold; 
background-color:#D8DADF; padding-left:10px;" >Email :</td><td 
style="background-color:#D8DADF; padding-left:10px;" width="65%" 
>'.$_REQUEST['email'].'</td></tr>
				<tr><td width="35%"  style="font-weight: bold; 
background-color:#D8DADF; padding-left:10px;" >Web site :</td><td 
style="background-color:#D8DADF; padding-left:10px;" width="65%" 
>'.$_REQUEST['company'].'</td></tr>
				<tr><td width="35%"  style="font-weight: bold; 
background-color:#D8DADF; padding-left:10px;" >Message :</td><td 
style="background-color:#D8DADF; padding-left:10px;" width="65%" 
>'.$_REQUEST['message'].'</td></tr></table>';
	$subject = 'ENQUIRY FORM';
	$to = "ramkumar@spiderindia.com";	
	ini_set("sendmail_from", $email);		
	$nam= $_REQUEST["name"];
	//$email=$_REQUEST['email'];
	$email="rkram90be@gmail.www.com";
		$headers   = array();
		$headers[] =  "Reply-To: {$nam} <$email>";
		$headers[] = "Return-Path: {$nam} <$email>"; 
		$headers[] =  "From: {$nam} <$email>";
		$headers[] =  "MIME-Version: 1.0";
		$headers[] = "Content-type: text/html; charset=iso-8859-1";
		$headers[] =  'Message-ID: <' . $_SERVER['REQUEST_TIME'] . 
md5($_SERVER['REQUEST_TIME']) . '@' . $_SERVER['SERVER_NAME'] . '>';
		$headers[] = "Organization: Sender Organization";
		$headers[] =  "Subject: {$subject}";
		$headers[] = "X-Priority: 0";
		$headers[] = "X-MSMail-Priority: Normal";
		$headers[] = "X-Sender-IP: {$_SERVER['REMOTE_ADDR']}";
		$headers[] =  "Bcc: ".MONITORADDRESS;
		$headers[] = "X-Mailer: PHP/". phpversion();	
			
		$return = "-f$email";	
	$bool=mail($to,$subject,$msg,implode("\r\n",$headers),$return);  //4th 
parameter "-f$email" if use <$email>
	if($bool)
	header("Location:thanks.html");
	else
	 header("location:contact.html");
}
else
header("Location:contact.html");
?>
</body>
</html>



Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2013-02-21 17:47 UTC] sixd@php.net
-Status: Open +Status: Feedback
 [2013-02-21 17:47 UTC] sixd@php.net
Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.

----------
Please state your actual problem.
 [2013-10-15 11:54 UTC] pecl-dev at lists dot php dot net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Dec 21 15:01:29 2024 UTC