gmail没有为发送电子邮件模板加载外部css [关闭]

I need to Send mail using phpmailer class and html email templates. php mailer send successful email templates but in gmail i cant see template. i think gmail no loaded external css.

template HERE

what's my problem ? how do fix this and show full template in gmail?!

Gmail preprocessor cut all in and after content.

All you have to do is to move your styles inline, you can use free tools like:

hope that helps.

While you technically can link to an external stylesheet in an email, any respectable email provider will block external shtylesheets. You need to do them inline.

<?php
$query=mysql_query(select * from table_name)
$table="";

$table .="<table border='1'  style='background-color:#C0C0C0;' >
    <tr>
     <th bgcolor='#E6E6FA'>Agent Name</th>
     <th bgcolor='#E6E6FA'>Count of  VOICE - Agent Name</th>
     <th bgcolor='#E6E6FA'>Average of Total Time</th>
     </tr>";
while($row=mysql_fetch_array($query))
    {

          $table .="<tr>";
          $table .= "<td>" . $row['agent_name'] . "</td>";
          $table .= "<td>" . $row['name_count'] . "</td>";
          $table .= "<td>" . $row['total_aht'] . "</td>";
      }
       $table .="</tr>";
         $table .= "<tr><td bgcolor='#E6E6FA'>Total</td><td bgcolor='#E6E6FA'>$y</td>
$to = "abc@gmail.com";
$subject="hii";
$headers = "MIME-Version: 1.0" . "
";
$headers .= "Content-type:text/html;charset=iso-8859-1" . "
";
$headers .= "From:<abc@gmail.com>" . "
";
$mail=mail($to,$subject, $table,$headers);
    ?>