php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #33193 some addresses work, some don't
Submitted: 2005-05-31 04:09 UTC Modified: 2005-05-31 07:18 UTC
From: temple64 at yahoo dot com Assigned:
Status: Not a bug Package: *Mail Related
PHP Version: 4.3.9 OS: unix
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: temple64 at yahoo dot com
New email:
PHP Version: OS:

 

 [2005-05-31 04:09 UTC] temple64 at yahoo dot com
Description:
------------
PHP version: 4.3.8-2.1 

I am emailing the results of a form...
it always looks like it succeeds...
If I put in my yahoo account, it shows up right away.
If I put in the address it needs to go to, it never shows up 
there.
If I send a test from my yahoo account to the address it needs 
to go to, it shows up right away.
I also tested the form to another address - no email shows up.
I tested again to my yahoo account, shows up immediately.
Why would the email succeed to some addresses and not others?
FYI, the FROM address is valid.


Reproduce code:
---------------
<?
if(!empty($_POST)) extract($_POST);
function param($Name, $http_vars)
      {  global $HTTP_POST_VARS;         
       if(isset($HTTP_POST_VARS[$Name]))
         return($HTTP_POST_VARS[$Name]);         
         return("");
         }
if ($Sign_Me_Up == "")
	{$Sign_Me_Up="No";}
	else
	$Sign_Me_Up="Yes, $Sign_Me_Up";
$from = "email@domain.com";
$to = "email@domain.com";
$subject = "request - destination: $PopularDestinations";
$body = "Source = $source\r\n
First Name = $First_Name\r\n
etc...";

if($from != "" && $to != "" && $subject != "")
  {
  $headers = "From: " . $from . "\n" .
             "To: " . $to . "\n" .
             "CC: " . $cc . "\n" .
             "BCC: " . $bcc;     
  $formsent= mail("", $subject, $body, $headers);
  if ($formsent == 1)
  	{
	print("Thank you for your request, we will respond to you shortly.");
	}
	else
	print("I'm sorry, there's a problem with your form. Please try again.");
  }
?>



Expected result:
----------------
I expect to get the Thank You statement and receive the email

Actual result:
--------------
email works only for some addresses.

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-05-31 07:18 UTC] sniper@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.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Mar 29 15:01:28 2024 UTC