页面上存在多个Fck Editor的验证方法

FCKeditor是一个专门使用在网页上属于开放源代码的所见即所得文字编辑器。它志于轻量化,不需要太复杂的安装步骤即可使用。它可和PHP、JavaScript、ASP、ASP.NET、ColdFusion、Java、以及ABAP等不同的编程语言相结合。

有时我们需要在一个页面上使用多个Fck的实例,首先需要按照id获取fck的实例。例如:

1 <FCKeditorV2:FCKeditor ID="fckDescription" runat="server" ToolbarSet="Basic" Height="250">
2 </FCKeditorV2:FCKeditor>

 

 使用FCKeditorAPI.GetInstance获取Fck实例。

 

1 function FCKeditor_OnComplete(editorInstance)
2 {
3     oEditer = FCKeditorAPI.GetInstance('fckDescription');
4 }

 

 使用这个方法就可以处理多个Fck的情况。

FCKeditorAPI介绍

 

posted @ 2010-03-09 08:39  ido  阅读(451)  评论(0编辑  收藏  举报