我在富文本编辑器中想要的只是粗体、斜体和链接。 外面有什么吗?
我正在开发一个小型网络应用程序,可以让用户输入日历事件。 对于事件的描述,我希望他们能够执行以下操作:
- 设置粗体文本
- 设置斜体文本
- 创建链接
- 绝对没有别的
例如,如果有人尝试从 Word 粘贴“讨厌的粉红色文本”,我不知道不希望它按照他们狡猾的小头脑所希望的方式工作:)。
到目前为止,我已经尝试过 YUI 富文本编辑器和 TinyMCE,但我还无法关闭足够多的功能来让我适应它们。 我可以让 TinyMCE 删除保存时的所有内容,但它仍然显示设计时的格式。 对我来说这似乎可用性很差。 另外,YUI 编辑器不输出 XHTML。
我认为 Markdown 编辑器最接近我想要的功能集,但我认为缺乏所见即所得会让人们感到困惑。
有人有解决办法吗?
I'm working on a small web application that will let users enter calendar events. For the description of the event, I would like them to be able to do the following:
- Set bold text
- Set italic text
- Create a link
- Absolutely nothing else
For example, if someone tries to paste "Nasty Hot Pink Text" from Word, I don't want that to work the way their devious little minds want it to :).
So far I've tried the YUI Rich Text Editor and TinyMCE, but I haven't been able to turn off enough of the features to make me comfortable with them. I can get TinyMCE to strip out everything on save, but it still shows the formatting at design time. That seems like bad usability to me. Plus, the YUI editor doesn't output XHTML.
I think the Markdown editor comes closest to the feature set that I want, but I think the lack of WYSIWYG would be confusing to people.
Anybody have a solution?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(6)
我认为 SPAW 编辑器是一个不错的选择,请看一下这里的演示:
http://www.spaweditor.com/spaw/demo/demo.php
i think SPAW editor is a good choice here take a look at demos here :
http://www.spaweditor.com/spaw/demo/demo.php
我输入的这个编辑器不是作为一个开源项目吗?
WMD 编辑器的分叉版本,可从 Dana Robinson 的 git 存储库 获取。
我以为我在博客上读过
Doesn't SO have this editor I am typing in as an open-source project?
A forked version of the WMD editor, available from Dana Robinson's git repository.
Thought I read it in the blog
FCKEditor 是我最喜欢的网页编辑器。
您可以自定义工具栏以根据需要提供尽可能多或尽可能少的内容。
The FCKEditor is my favorite web Editor.
You can customize the toolbar to give as much or as little as you want.
是的, http://cheaun.github.com/mooeditable/ 几乎只能做到这一点。
Yes, http://cheeaun.github.com/mooeditable/ can pretty much only do that.
您的答案是markItUp! 通用标记编辑器
“markItUp!是一个基于 jQuery 库的轻量级 JavaScript 插件。它允许您将任何文本区域变成标记编辑器。Html、Textile、Wiki Syntax、Markdown、BBcode 甚至您自己的标记系统都可以很容易实施。”
Your answer is markItUp! Universal markup editor
"markItUp! is a lightweight JavaScript plugin built on the jQuery library. It allows you to turn any textarea into a markup editor. Html, Textile, Wiki Syntax, Markdown, BBcode or even your own Markup system can be easily implemented."
看起来我会选择 TinyMCE,但实际上没有人将其作为答案发布! 如果您启用了粘贴插件,它会删除格式。
It looks like I'm going to be going with TinyMCE, but nobody actually posted that as an answer! If you have the paste plugin enabled, it does strip out formatting.