HTML5 富文本编辑器:Squire
Squire是一个HTML5的富文本编辑器,它提供了强大的跨浏览器的标准化,同时又是超级轻巧灵活。 只支持最新的浏览器。
Installation
- Download the source from neilj/Squire
- Copy the contents of thebuild/directory onto your server.
- Edit the<style>block in document.html to add the default styles you would like the editor to use (or link to an external stylesheet).
- In your application, instead of a<textarea>, use an<iframe src="path/to/document.html">.
- In your JS, attach an event listener to theloadevent of the iframe. When this fires you can grab a reference to the editor object throughiframe.contentWindow.editor.
- Use the API below with theeditorobject to set and get data and integrate with your application or framework.
本文由用户 jopen 自行上传分享,仅供网友学习交流。所有权归原作者,若您的权利被侵害,请联系管理员。
转载本站原创文章,请注明出处,并保留原始链接、图片水印。
本站是一个以用户分享为主的开源技术平台,欢迎各类分享!