i want to use to html table in a php variable so that i can use that variable in php mail and that mail should renders the html table. I used EOD but its not working. Here is the code i'm using which is not working.
$body1 = <<<EOD
<br><br>
<h3 align="center">Career Details</h3>
<table border="1" width="100%">
<col width="50%">
<col width="50%">
<tr>
<td style="text-align:left;">Name: $nameField </td>
<td style="text-align:left;">Email: $emailField </td>
</tr>
<tr>
<td style="text-align:left;">Date of Birth: $dob</td>
<td style="text-align:left;">Passport Number: $passportnum</td>
<tr>
<td style="text-align:left;">Gender: $gender</td>
<td style="text-align:left;">Nation: $nation</td>
<tr>
<td style="text-align:left;">Phone: $phone</td>
<td style="text-align:left;">Prefered Location: $location</td>
<tr>
<td style="text-align:left;">Area of Interest: $areaofinterest</td>
</table>
EOD;
$body=$body1;
$headers = 'From: noreply@mydomain.com';
if(mail($mailto, $emailSubject, $body, $headers)){
header ('Location: http://www.mydomain.net?page_id=664');
}