0

以下 PHP 发送邮件功能可在 Firefox 中使用,但在至少一个版本的 Internet Explorer (10.0.5) 上不再适用。我不确定这是什么时候发生的,但似乎与 IE 中的某种形式的变化或我们的主机迁移准备 4 到 5.2 PHP 有关。请注意,即使在 PHP 5.4 环境下,该函数也可以在 Firefox 中正常工作。

受影响的功能如下,任何帮助将不胜感激(注意样式项目已删除以使代码更易于查看/调试):

<?php
$comments=nl2br($comments);
$date=date("F d,Y h:i:s a");

$body=" <table width='650' align='left' cellspacing='0' cellpadding='0' style=' background-color:#FFFFFF; margin-bottom:10px;'>
<tr><td colspan='2' style='text-align:left; background-color:#FFFFFF; font-family:Arial, Helvetica, sans-serif; font-size:13px; color:#000000; font-weight:bold; padding:5px;'>Quote Request:&nbsp;&nbsp;&nbsp;&nbsp;<span style='font-size:11px; color:#000000; font-weight:normal;'>Submitted &nbsp;".$date."&nbsp;</span><hr></td>
</tr>

<tr>
<td>Name:</td>
<td>".$_REQUEST['name']."</td>
</tr>
<tr>
<td>Company:</td>
<td>".$_REQUEST['company']."</td>
</tr>
<tr>
<td>Title:</td>
<td>".$_REQUEST['title']."</td>
</tr>
<tr>
<td>Phone #:</td>
<td>".$_REQUEST['phone']."</td>
</tr>
<tr>
<td>Email:</td>
<td>".$_REQUEST['email']."</td>
</tr>
<tr>
<td>Product or service type:</td>
<td>".$_REQUEST['product']."</td>
</tr>
<tr>
<td>Description of the product or service:</td>
<td>".$_REQUEST['description']."</td>
</tr>
<tr>
<td>Project type:</td>
<td>".$_REQUEST['product_type']."</td>
</tr>
<tr>
<td>Project overview:</td>
<td>".$_REQUEST['overview']."</td>
</tr>
<tr>
<td>Please summarize project's objectives:</td>
<td>".$_REQUEST['summarize']."</td>
</tr>
<tr>
<td># of users to test (if applicable):</td>
<td>".$_REQUEST['user_test']."</td>
</tr>
<tr>
<td>Supported computing platforms (if applicable):</td>
<td>".$_REQUEST['supported_computing']."</td>
</tr>
<tr>
<td>Project depth required:</td>
<td>".$_REQUEST['depth']."</td>
</tr>
<tr>
<td>Project's status:</td>
<td>".$_REQUEST['project_status']."</td>
</tr>
<tr>
<td>When would you like to begin?</td>
<td>".$_REQUEST['like_begin']."</td>
</tr>
<tr>
<td>When will you need the results?</td>
<td>".$_REQUEST['result']."</td>
</tr>
<tr>
<td>How should we contact you?</td>
<td>".$_REQUEST['Contact']."</td>
</tr>
</table>";

if($_POST['email']!="")
{

    $body =$body;
    $subject="Quote Request";
    $headers  = 'MIME-Version: 1.0' . "\r\n";
    $headers .= "Content-type: text/html; charset=iso-8859-1\r\n";
    $headers .= "From: " .$_REQUEST['email']. "\r\n";
    $to="details@ourURL.com";
   // $to="";
    mail($to,$subject,$body,$headers);
4

0 回答 0