php - Cannot send table format to gmail using PHPmailer. -


i used msghtml() function send mail body. ishtml enabled in mailer script. html tags
rendered in mail, inline style worked. table not rendered in gmail. inbox showing plain text. images displayed clearly.

php code

$pd_details.='   <table >    <th>prod no  |</th>  <th>prod name   |</th> <th>prod price   |</th> <th>prod quantity   |</th> <th>prod image   |</th>       <tr><td>'.$c.'</td><td>'.$pname.'</td><td>'.$total.'</td><td>'.$quant.'</td<td>'.$pdimg.'</td></tr> </table>  total price : '.$sum.' '; 

try this...                    $from='sender details';                   $to='receiver email address';                   $headers .= 'mime-version: 1.0' . "\r\n";                   $headers .= 'content-type: text/html; charset=iso-8859-1' . "\r\n";                   $headers .= 'from:'.$from. "\r\n";                    $body='<table >        <th>prod no  |</th>  <th>prod name   |</th> <th>prod price   |</th> <th>prod quantity   |</th> <th>prod image   |</th>           <tr><td>'.$c.'</td><td>'.$pname.'</td><td>'.$total.'</td><td>'.$quant.'</td<td>'.$pdimg.'</td></tr>     </table>';                    $subject="subject";                   ini_set("sendmail_from",$from);                   @mail($to,$subject,$body,$headers);   

Comments

Popular posts from this blog

java - How to specify maven bin in eclipse maven plugin? -

Error while updating a record in APEX screen -

c++ - In an add-in in Excel, written in C(++), how does one get the name of the function which called into the addin? -