Hi I have a form to mail script that I need to edit.
[CODE]
$List= ‘
<html>
<head>
<title>Orders</title>
</head>
<table border=1>
<tr>
<td>
<strong><u><font face=”comic sans ms” color=”#ff3705″><center>Product Code</center></font></strong></u>
</td>
<td>
<strong><u><font face=”comic sans ms” color=”#ff3705″><center>Product</center></font></strong></u>
</td>
<td>
<strong><u><font face=”comic sans ms” color=”#ff3705″><center>Quantity</center></font></strong></u>
</td>
</tr>
$kode
</table>
</html>
‘;
###############################################################################################
$headers = ‘MIME-Version: 1.0’ . “rn”;
$headers .= ‘Content-type: text/html; charset=iso-8859-1’ . “rn”;
$headers .= ‘From: [email protected]’ . “rn”;
$recipient=$EMail;
$subject=”RE: ORDER”;
$name=”3D-Xact”;
$email=”[email protected]”;
$message=$List;
$sucses = mail($recipient, $subject, $message, $headers);
I have some PHP script that needs to be run in that email to complete the table of products.
Here is the PHP Code:
[CODE]
<?php
$New=”SELECT * FROM products”;
$result = mysql_query($New);
$num=mysql_num_rows($result);
$x = 0;
while($x < $num){
$Code = mysql_result($result,$x,’code’);
$Prod = mysql_result($result,$x,’prod’);
if (isset($_SESSION[$Code])){
?>
<tr>
<td>
<center><strong><font face=”comic sans ms” color=”#3300ff” size=”2″>
<?php
echo $Code ;
?>
</font></strong></center>
</td>
<td>
<center><strong><font face=”comic sans ms”
color=”#3300ff” size=”2″>
<?php
echo $Prod ;
?>
</font></strong></center>
</td>
<td>
<center>
<?php
echo $_SESSION[$Code]
?>
</center>
</td>
</tr>
<?php
}
$x++;
}
?>
Is this possible and if so how?
Please help me. ?