I was pulling something from /
and found that it did not have any of the dynamically arranged titles. When I went to edit the page, I found a surprise.
I had originally entered a hand-typed:
<script src="/wp-content/javascripts/wrapped-book-table.cgi"></script>
However, while the SCRIPT tag was still there, it was mangled:
<script src="/wp-content/javascripts/wrapped-book-table.cgi" type="mce-no/type" data-mce-src="/wp-content/javascripts/wrapped-book-table.cgi"></script>
What converted the first into the second one, and what does "mce" refer to? This is not something I would have entered, and the type of "mce-no/type" probably defeated the JavaScript being treated in JavaScript.
(And what can I do to prevent the transformaation from recurring?)
I was pulling something from https://CJSHayward/books/
and found that it did not have any of the dynamically arranged titles. When I went to edit the page, I found a surprise.
I had originally entered a hand-typed:
<script src="/wp-content/javascripts/wrapped-book-table.cgi"></script>
However, while the SCRIPT tag was still there, it was mangled:
<script src="/wp-content/javascripts/wrapped-book-table.cgi" type="mce-no/type" data-mce-src="/wp-content/javascripts/wrapped-book-table.cgi"></script>
What converted the first into the second one, and what does "mce" refer to? This is not something I would have entered, and the type of "mce-no/type" probably defeated the JavaScript being treated in JavaScript.
(And what can I do to prevent the transformaation from recurring?)
Share Improve this question edited May 11, 2019 at 0:05 fuxia♦ 107k39 gold badges255 silver badges459 bronze badges asked Apr 12, 2017 at 7:42 Christos HaywardChristos Hayward 639 bronze badges 3- just a quick question, did you add that into the post or into your template? – marvinpoo Commented Apr 12, 2017 at 7:48
- 1 Lets repeat together, the editor is for content, not for code :(. – Mark Kaplun Commented Apr 12, 2017 at 8:21
- @MarkKaplun so true! – marvinpoo Commented Apr 12, 2017 at 8:22
2 Answers
Reset to default 0This is a known bug with TinyMCE. That is the standard text editor in WP. When you hit refresh whilst editing a page it adds those tags to javascript. https://github/tinymce/tinymce/commit/5f320ac2acda15902b0488df1b7d85bf5c24ef94
However it is marked as fixed some time ago (2015) so perhaps your site is not up to date? Or of course perhaps it has resurfaced!
(And what can I do to prevent the transformaation from recurring?)
Start with not putting Javascript into your Editor.
发布者:admin,转转请注明出处:http://www.yc00.com/questions/1745503928a4630542.html
评论列表(0条)