I am trying to sent an email from bash script which should have HTML table in body , I am using mail command in Redhat . but its keep sending me as Text file .
difference=`expr $artu_removed - $artu_added`
mail -s "Built notification" test@gmail.com << EOF
<html>
<head><title></title>
</head>
<body>
<table>
<tr>
<Td> Before </td> <td>after </td> <td>differece </td>
</tr>
<tr>
<Td> $_before </td> <td>$_after </td> <td>$difference </td>
</tr>
</table>
Before:$_before
After:$_after
Difference:$difference
</body>
</html>
EOF
Can any one please let me know what shall I do, I am using Redhat, Not ubuntu
Thanks