您现在的位置:龙卷风首页 ›› 网络编程 ›› 阅读文章

FCKeditor JS API

FCKeditor API

FCKeditor编辑器功能很强,没想到还留给设计人员js API接口,真实太酷了。以前不知道,自己写上传图片的程序与之集成,感觉非常困难。有了API接口就易如反掌了。


  1// FCKeditor_OnComplete is a special function that is called when an editor
  2// instance is loaded ad available to the API. It must be named exactly in
  3// this way.
  4function FCKeditor_OnComplete( editorInstance )
  5{
  6    // Show the editor name and description in the browser status bar.
  7    document.getElementById('eMessage').innerHTML = 'Instance "'  +  editorInstance.Name + '" loaded - ' + editorInstance.Description ;
  8
  9    // Show this sample buttons.
 10    document.getElementById('eButtons').style.visibility = '' ;
 11}

 12
 13function InsertHTML()
 14{
 15    // Get the editor instance that we want to interact with.如果你用的是FCKeditor.Net,直接用在.net中的ID就可以了。
 16 &nb

作者 不见不散 本文仅代表作者观点,与龙卷风资讯网立场无关。

我来说两句

1 楼 站长 发表于 2008-8-8 From IP: 202.104.42.126
更多内容请参考官方网址: http://docs.fckeditor.net/FCKeditor_2.x/Developers_Guide/JavaScript_API
作者主页: http://www.ljf.cn
内容/Content