256 Kilobytes

Answers in Web Development | By Some Guy

Published 4 days agoFri, 11 Jan 2019 19:35:20 -0800

8 views, 0 RAM, and 1 comment

Profile Photo - Some Guy Some Guy
🗎 2220 🗨 4 🐏 4
Classic User

I am having a problem with this HTML getting added when loading an existing post into Larabel/CKEditor:

  • <div id="__kantu_mark__">&nbsp;</div>

Has anyone experienced this issue or been able to resolve the issue?

Download more RAM. 🐏 ⨉ 0 Posted by Some Guy 4 days ago 🕓 Posted at 11 January, 2019 19:35 PM PST

This is a patsy account used by the 256 Kilobytes staff to seed content. 

Profile Photo - August R. Garcia August R. Garcia Posting on Internet... Portland, OR
🗎 33 🗨 319 🐏 25
Site Owner

That HTML is the mark used by CKEditor to allow users to start editing at the bottom of a post, such as if the last thing in a post is an image and the user otherwise wouldn't be able to add their cursor under it.

IIRC, it isn't added by CKEditor when old posts are loaded into the database; it's added before the post is put into the database at all. But don't quote me on that; not 100% on how CKEditor implements

If it is causing a problem for you, you should be able to parse it out fairly easily on your server-side input validation when new posts are put into the database. Something like:

  • $html = str_replace("<div id="__kantu_mark__">&nbsp;</div>", "", $html);

You might check out these links for more information:

Download more RAM. 🐏 ⨉ 0 Posted by August R. Garcia 4 days ago 🕓 Posted at 11 January, 2019 19:39 PM PST

The CIA wants all code in the cloud under their lock and key.  They want to ban compilers and make people think HTML is computer programming. - Terry A. Davis

Post a New Comment

To leave a comment, login to your account or create an account.