首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >TinyMCE删除了我的代码并更改了我的html,所有的解决方案都不起作用。

TinyMCE删除了我的代码并更改了我的html,所有的解决方案都不起作用。
EN

Stack Overflow用户
提问于 2017-09-04 19:47:47
回答 2查看 230关注 0票数 0

我正在使用微型MCE编辑器,当我保存我的html文本时,它会自动删除我的内容,我在不同的论坛上审查了许多解决方案,但都没有解决这个问题。

代码语言:javascript
复制
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">  <html xmlns="http://www.w3.org/1999/xhtml">  <head>  <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />  <title>Receipt Creation Failure</title>  </head>    <body style="font-family:Arial, Helvetica, sans-serif; font-size:12px; color:#333;">  <div style="border:1px; border-color:#003; border-style:solid; width:600px; float:left">        <div style="float:left; padding-top:20px; width:560px; padding:20px; min-height:200px; "> <strong>Dear Team, </strong><br />      <br />    There was a payment attempt from the Test named <b>{TestName}</b> placed at <b>{TestLocation}</b>. <br This is a system generated message, please do not reply to this email address since it is not monitored.<br />      <br />      <strong>Thank you <br />      xyz Support Team </strong></div>    <div style="width:580px; padding:10px; background-color:#132c4d; height:10px; text-align:right; clear:both; color:#FFF; text-decoration:none"><a style="color:#FFF; text-decoration:none;" href="https://emaar.service-now.com/" target="_blank">Contact Us</a> | <a href="http://xyz.ae/" target="_blank" style=" color:#FFF; text-decoration:none;">xyz.ae</a></div>  </div>  </body>  </html>

当我保存此信息时,它会将其转换为

代码语言:javascript
复制
<p>Receipt Creation Failure</p>
<div style="border: 1px; border-color: #003; border-style: solid; width: 600px; float: left;">
<div style="float: left; padding-top: 20px; width: 560px; padding: 20px; min-height: 200px;"><strong>Dear Team, </strong><br /> <br /> There was a payment attempt from the Test named <strong>{TestName}</strong> placed at <strong>{TestLocation}</strong>. <br /> <br /> <strong>Thank you <br /> xyz Support Team </strong></div>
<div style="width: 580px; padding: 10px; background-color: #132c4d; height: 10px; text-align: right; clear: both; color: #fff; text-decoration: none;"><a style="color: #fff; text-decoration: none;" href="https://emaar.service-now.com/" target="_blank">Contact Us</a> | <a style="color: #fff; text-decoration: none;" href="http://xyz.ae/" target="_blank">xyz.ae</a></div>
</div>

请帮帮忙。

EN

Stack Overflow用户

发布于 2017-09-07 21:33:48

你试过tinyMCE.activeEditor.getContent({format : 'raw'});了吗?

票数 1
EN
查看全部 2 条回答
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/46036381

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档