In the offical example sample08.html
there are 2 function like this
this 2 function is work, but if I combine this 2 function to
In FF, there are nothing alert in the alert box
in IE7 sometimes it alert nothing, sometimes is has a error "permission denied"
can any one tell me why this case happened????
there are 2 function like this
function GetContents() { // Get the editor instance that we want to interact with. var oEditor = FCKeditorAPI.GetInstance('FCKeditor1') ; // Get the editor contents in XHTML. alert( oEditor.GetXHTML( true ) ) ; // "true" means you want it formatted. } function ExecuteCommand( commandName ) { // Get the editor instance that we want to interact with. var oEditor = FCKeditorAPI.GetInstance('FCKeditor1') ; // Execute the command. oEditor.Commands.GetCommand( commandName ).Execute() ; }
this 2 function is work, but if I combine this 2 function to
function change(){ var oEditor = FCKeditorAPI.GetInstance('FCKeditor1') ; oEditor.SetData( 'testing' ) ; alert( oEditor.GetXHTML( true ) ) ; //document.getElementById('FCKeditor1_READONLY').innerHTML=oEditor.GetXHTML( true ); }
In FF, there are nothing alert in the alert box
in IE7 sometimes it alert nothing, sometimes is has a error "permission denied"
can any one tell me why this case happened????
Re: Strange case in the offical example
Re: Strange case in the offical example
I have try this.....but it didn't help
function FCKUpdateLinkedField(id)
{
try
{
if(typeof(FCKeditorAPI) == "object")
{
FCKeditorAPI.GetInstance(id).UpdateLinkedField();
}
}
catch(err)
{
}
}
Re: Strange case in the offical example
Use the events: http://docs.fckeditor.net/FCKeditor_2.x ... Script_API
Re: Strange case in the offical example
but when there are more than 1 FCKeditor in the same page, the same error occurs again, anyway thank you for your help~~