weixin_33712881 2018-01-30 09:03 采纳率: 0%
浏览 13

标签未解释

I have a problem with my script.

I Insert in my bdd my mails thanks to the Outlook API. To make an Insert I get the source code of my mail then insert it, so far no problem.

After that I make a select to display the mail in another page. My problem is that

the source code is not interpreted

, it shows me all the tags, I don't understand why it doesn't read them.

my echo that displays my emails following the SELECT. My variable $result[body] displays the source code of the email... How do I force it to convert?

 echo nl2br('<!DOCTYPE html>'.'<div class="emailBody">'.'<div class="list-group-item-heading premier">' . $result[from_mail] . '</div>' ."
". '<div class="second">' . $result[recei] .'</div>' ."
". '<div id="post1" class="trois azerty">' . '<p class="azerty bodypreview_1">' . $result[subject]. '</p>'."
".'<div class="demasquer">' .'<p class="body_1">'.$result[body].'</p>'.")".'</div>'.'</div>'. '</div>');

</div>
  • 写回答

1条回答 默认 最新

  • weixin_33726318 2018-02-01 12:12
    关注

    I've been able to help myself thanks to the use of "html_entity_decode". Now my tags are being interpreted. Correction:

    echo  html_entity_decode('<!DOCTYPE html>'  .'<div class="emailBody">'.'<div class="list-group-item-heading premier">' . $result[from_mail] . '</div>' ."
    ". '<div class="second">' . $result[recei] .'</div>' ."
    ". '<div id="post1" class="trois azerty">' . '<p class="azerty bodypreview_1">' . $result[subject]. '</p>'."
    ". '<head>' .'</head>'.'<div class="demasquer">' .'<p class="body_1">'. $result[body] .'</p>'.'</div>'.'</div>'. '</div>');

    </div>
    
    评论

报告相同问题?

悬赏问题

  • ¥15 r语言蛋白组学相关问题
  • ¥15 Python时间序列如何拟合疏系数模型
  • ¥15 求学软件的前人们指明方向🥺
  • ¥50 如何增强飞上天的树莓派的热点信号强度,以使得笔记本可以在地面实现远程桌面连接
  • ¥20 双层网络上信息-疾病传播
  • ¥50 paddlepaddle pinn
  • ¥20 idea运行测试代码报错问题
  • ¥15 网络监控:网络故障告警通知
  • ¥15 django项目运行报编码错误
  • ¥15 STM32驱动继电器