取得FCKeditor的值及其他方法介绍
//获取格式化的编辑器内容
function getEditorContents(){
var oEditor = FCKeditorAPI.GetInstance("content");
alert(oEditor.GetXHTML(true));
}
//向编辑器插入指定代码
function insertHTMLToEditor(codeStr){
var oEditor = FCKeditorAPI.GetInstance("content");
if (oEditor.EditMode==FCK_EDITMODE_WYSIWYG){
oEditor.InsertHtml(codeStr);
}else{
return false;
}
}
//统计编辑器中内容的字数
function getLength(){
var oEditor = FCKeditorAPI.GetInstance("content");
var oDOM = oEditor.EditorDocument;
var iLength ;
if(document.all){
iLength = oDOM.body.innerText.length;
}else{
var r = oDOM.createRange();
r.selectNodeContents(oDOM.body);
iLength = r.toString().length;
}
alert(iLength);
}
//执行指定动作
function ExecuteCommand(commandName){
var oEditor = FCKeditorAPI.GetInstance("content") ;
oEditor.Commands.GetCommand(commandName).Execute() ;
}
//设置编辑器中内容
function SetContents(codeStr){
var oEditor = FCKeditorAPI.GetInstance("content") ;
oEditor.SetHTML(codeStr) ;
}
分享到:
相关推荐
FCKeditor 2.4.3详细使用方法
fckeditor和使用方法,可以上传图片,flash
.NET fckeditor编辑器的设置和使用方法
FCKEDITOR 常用上传方法及上传位置
fckeditor的MVC版及js使用fckeditor的方法,初步的,深入的请自行研究
Fckeditor皮肤Fckeditor皮肤Fckeditor皮肤Fckeditor皮肤Fckeditor皮肤Fckeditor皮肤
FCKeditor使用方法详解.doc
1 FCKeditor的下载及介绍 4 1.1 下载地址 4 1.2 FCKeditor下载包的介绍 4 2 FCKeditor的目录和文件精简 4 3 在页面创建FCKeditor 4 3.1 Js创建FCKeditor实例: 4 3.1.1 方法一:内嵌方法(推荐) 4 3.1.2 方法二:替换...
ASP.NET 文本编辑器 FCKeditor 使用方法详解 FCKeditor 是一个功能强大且流行的 ASP.NET 文本编辑器,提供了许多实用的功能,如格式化文本、插入图片、上传文件、创建表格等。下面将详细介绍如何使用 FCKeditor 在 ...
fckeditor组件是一个为文本域加入其它功能的组件,引入js文件即可,比如设置字体,颜色,插入图片等!!
FCKeditor使用方法技术详解。...FCKeditor是目前最优秀的可见即可得网页编辑器,本文详细介绍其安装,使用FCKEditor的各项功能,常用设置,配置方法; 另外还提供了FCKEditor API,精简FCKEditor文件控件大小的方法。
FCKeditor是一个专门使用在网页上属于开放源代码的所见即所得文字编辑器。压缩包里附有FCKeditor在.net中的使用方法
FCKeditor开发jar包及fckeditor文件夹
fckeditor 带编辑公式的具体方法
由于目前的版本提供的FCKEDITOR仅提供了JAVASCRIPT式的整合,因此,这里仅讲述如何应用JAVASCRIPT来整合FCKEDITOR到站点中,当然,其他各种语言的整合,你可以参考_samples文件夹中的例子来完成 1,假如编辑器已经安装在你...
网络上有很多FCKeditor的用法,大多数是互相抄袭,或者...但是这个FCKeditor使用方法详解--图文详解讲解的非常清楚,关键还是附带图片,让人一看就一目了然,很容易看懂。另外还收录了fckeditor的瘦身。很全面的哦--
FCKeditor是目前最优秀的可见即可得网页编辑器之一用于文本编辑的工具,支持多种方法调用
fckeditor编辑器使用方法欢迎大家及时下载使用
FCKeditor配置方法 如果不懂,这是很好的教材!
NULL 博文链接:https://zyzhongyang.iteye.com/blog/839996