Comments (6)
@giuem dalao
from wp-editor.md.
最近在忙期末项目,还有期末考
我下午看一下……
from wp-editor.md.
问题出在 strip_tags
这个函数
https://secure.php.net/manual/zh/function.strip-tags.php
Note:
HTML 注释和 PHP 标签也会被去除。这里是硬编码处理的,所以无法通过 allowable_tags 参数进行改变。
解决办法可能会有点脏, 比如先把 <!--more-->
替换成 {!--more--}
之类的,然后过滤完 xss 再替换回去
from wp-editor.md.
你这个说得我好迷糊...
from wp-editor.md.
在 https://github.com/JaxsonWang/WP-Editor.MD/blob/master/Jetpack/markdown/xsshtml.class.php#L88 这里就已经把 <!--more-->
过滤了,因为这是 HTML 注释。
所以你只要在这句之前把 <!--more-->
替换成 {!--more--}
,然后在 getHtml()
的时候把 {!--more--}
换回 <!--more-->
from wp-editor.md.
解决了,谢dalao
from wp-editor.md.
Related Issues (20)
- [BUG]wordpress 5.8.2 代码行数和代码高亮主题失效
- [BUG] HOT 3
- [BUG] 因cdn.jsdelivr.net现在加载慢,能否更换快一点的cdn HOT 1
- [Feature] 图片显示的优化建议 HOT 2
- [Feature] 自动添加其他主题内置的短代码插入 HOT 3
- [BUG]插入图片时无法显示 HOT 1
- [BUG]复制粘贴的图片显示模糊 HOT 3
- [BUG] 多行代码无法显示,关闭WP-Editor.md后恢复正常 HOT 18
- 严重![BUG] HOT 2
- [BUG]WP-Editor.md 10.2.1预览与实际显示不一样的问题。 HOT 1
- [BUG] 代码块单行内容过长引发的显示异常 HOT 3
- 升级插件之后,变成以下情况了,帮忙看下【已解决】 HOT 2
- [BUG]图标显示问题 HOT 2
- [Feature] 行内代码和代码块无法区分配置CSS
- [Feature] 行内代码和代码块无法区分配置CSS
- [BUG]sms 图片上传失败。好像是sms大陆地区不能访问导致。是否可以修复? HOT 5
- [BUG] 无法启用插件,因为它引起了一个致命错误(fatal error)。 HOT 2
- [BUG] 几个小问题 HOT 5
- 如何居中显示图片 HOT 3
- [BUG] 最近编辑文章的时候,编辑窗口内显示为HTML格式而非Markdown格式了 HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from wp-editor.md.