使用 Javascript 或所见即所得打开和编辑 html 页面的片段

Open and edit segments of an html page using Javascript or WYSIWYG

本文关键字:html 片段 编辑 Javascript 所见即所得 使用      更新时间:2023-09-26

因为我正在制作一个教育网站,上面有练习题,我有一个老师的私人登录区,我想知道是否可以编辑包含问题的其他页面的 HTML,比如老师是否希望添加更多。

我见过所见即所得的编辑,就像 CKEditor 一样,但到目前为止,他们对实现和功能让我感到困惑,任何建议将不胜感激:)

此外,如果可能只显示代码的一部分,因为使用它的老师没有任何经验,因此尽可能少的技术难度也将不胜感激:)

如果您有任何问题或代码要求,请:)谢谢:)

<div class="main_story" style="margin-bottom:20px;">
                        <p class="sentence">the word to go here -></p>
                        <input id="you" name="input" class="sentence" type="text" size="7">
                        <p class="sentence">is you</p>
                        <button style="float:right" id="correct" onClick="Check('you', 'bShow');">Check answer</button>
                        <input style="float:right" name="bShow" id="bShow" type="checkbox" value="">
                        <p class="sentence" style="float:right">correct</p>
                    </div>

只有真正需要更改的按钮

的onClick调用,id可能也需要更改,是否有任何所见即所得的编辑器可以编辑这种原始格式的html? :/

查看 aloha: http://aloha-editor.org/