duanfengwang9157 2017-08-11 07:02
浏览 103
已采纳

发送到hotmail时的Php邮件功能将其作为加密方式接收

I have created a standalone email templater software. it all works on gmail, yahoo and even on outlook and other business emails. But the problem is on hotmail . When i tried to send some sample email,on receiving it automatically encrypts the sent email . something like this

†Ù¥…æ¶+exK« „ÒJÖ«µêÒãÚrF {ûb¶W¬·)^µìmrë-r‰h­Ê%¢¶åiÉ?²Ü¥{ø^iÖèw'b¾) ²·&j Úµë–+^r‰¿Šf zÏÒà@4Ñ À™à…è †ÝúÒœp‰Ûa÷Í)Ç÷b¾—%jË-{\ºË\¢Z+&¬wúirV¬²×±µË¬µÊ%¢±Þ­è¬¶¢ú+™«b¢{ajܨº·ª¹ë-y×讉躻-®‰à²–§²Ü¥yÊ%¢ºÞtK« „ÒJÖ«µêÒãÚrF >>{û)j춺'ºÓ†+)iÉè¬uë"‚w~Šì™©ejwfyØ®™»¬Šw¬²)ÀºËkjXš¶‡(š—­z‰í…ê'–)Þ™ªäz×è®Ø^š‹-i÷è

heres my code:

<?php
    $to = $_GET['email'];
    $nameOfClient = $_GET['username'];
    $StarterPackage = "
    <html>
    <head>
    <title>Sample Email Templater</title>
    </head>
    <body>
    <span style='color:black;'>
     This package is designed for small and medium business in Australia to 
     compete on the online market for the most affordable price. If you 
     don't have a website yet, it's the best timing for your business to 
     have one now. If you already have a website it's the perfect time to 
     boost your ranking online for your business advantage and needs.</span>
    </body>
    </html>
    ";

    $headers[] = "MIME-Version: 1.0";
    $headers[] = "Content-type:text/plain; charset=ISO-8859-1";
    $headers[] = "Content-Transfer-Encoding: base64";
    $result = mail($to,$subject,$StarterPackage,implode("
", $headers)); 
?>
  • 写回答

1条回答 默认 最新

  • dskm94301 2017-08-11 07:10
    关注

    Try setting headers as follows since you are using html elements in the body

    $headers[] = "MIME-Version: 1.0";
    $headers[] = "Content-Type: text/html; charset=ISO-8859-1";
    

    also check by removing the following code if any problem still exists

    $headers[] = "Content-Transfer-Encoding: base64";
    
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥100 嵌入式系统基于PIC16F882和热敏电阻的数字温度计
  • ¥20 BAPI_PR_CHANGE how to add account assignment information for service line
  • ¥500 火焰左右视图、视差(基于双目相机)
  • ¥100 set_link_state
  • ¥15 虚幻5 UE美术毛发渲染
  • ¥15 CVRP 图论 物流运输优化
  • ¥15 Tableau online 嵌入ppt失败
  • ¥100 支付宝网页转账系统不识别账号
  • ¥15 基于单片机的靶位控制系统
  • ¥15 真我手机蓝牙传输进度消息被关闭了,怎么打开?(关键词-消息通知)