Hi,
I'm working on integrating the "FCKeditor" (www.fckeditor.com) with SmartClient (funny product name, but it's the best I've found with a commercial license in addition to LGPL).
I plan to share the working code with this forum, since based on the various posts I've read others need something similar...
I have the FCKeditor operational on an HTML page, along with my SC code.
The FCKeditor works fine when running on the HTML page (with and without SC code running).
The challenge is getting the FCKeditor to display properly and process events when running within the SmartClient framework. I'm guessing there's some "event plumbing" that's going to be required to get this the two to cooperate.
I'm using an HTMLFlow object in SC to load an HTML fragment that implements the FCKeditor Javascript code (code that works in HTML on this same page).
The first problem is the "oFCKeditor.Config... line that needs to interact with a DIV tag in the page's HTML DOM space is failing. When the oFCKeditor control "wakes up" inside the HTMLFlow object, it can't see the "xToolbar" DIV tag that sits in the HTML page above it. This results in an error message, but the control continues to initialize by default.
This behavior leads me to believe there's some difference in DOM scope or something going on with the HTMLFlow object that's hiding the xToolbar DIV tag. This xToolbar DIV tag allows the FCKEditor toolbar strip to sit at the very top of the HTML page, so to the user it appears like a normal text editor.
Then, each instance of the FCKeditor control shares this common text editor toolbar at the top fo the web page - at least that's the way it works in a plain HTML page...
What I see is a moment where the SmartClient interface appears, followed by what seems like a different page that only shows the FCKeditor (and then I can't launch the javascript:isc.showConsole() to see what happened).
Any ideas / suggestions / examples for integrating a 3rd party control with SC like this?
Rick
I'm working on integrating the "FCKeditor" (www.fckeditor.com) with SmartClient (funny product name, but it's the best I've found with a commercial license in addition to LGPL).
I plan to share the working code with this forum, since based on the various posts I've read others need something similar...
I have the FCKeditor operational on an HTML page, along with my SC code.
The FCKeditor works fine when running on the HTML page (with and without SC code running).
The challenge is getting the FCKeditor to display properly and process events when running within the SmartClient framework. I'm guessing there's some "event plumbing" that's going to be required to get this the two to cooperate.
Code:
isc.HTMLFlow.create({ ID:"FCKeditorHTML", align:"left", height:"100", width:"300", evalScriptBlocks: true, contentType:"fragment", styleName:"exampleTextBlock", contentsURL:"FCKeditor.html" }), FCKeditor.html: <script type="text/javascript" src="../FCKeditor/fckeditor.js"></script> <script type="text/javascript" language="javascript"> var oFCKeditor = new FCKeditor( 'FCKeditor_SmartClient' ); oFCKeditor.BasePath = "../FCKEditor/"; oFCKeditor.Height = 100 ; oFCKeditor.Config[ 'ToolbarLocation' ] = 'Out:xToolbar' ; oFCKeditor.Value = 'This is some <strong>sample text in SmartClient!</strong>' ; oFCKeditor.Create() ; </script>
The first problem is the "oFCKeditor.Config... line that needs to interact with a DIV tag in the page's HTML DOM space is failing. When the oFCKeditor control "wakes up" inside the HTMLFlow object, it can't see the "xToolbar" DIV tag that sits in the HTML page above it. This results in an error message, but the control continues to initialize by default.
This behavior leads me to believe there's some difference in DOM scope or something going on with the HTMLFlow object that's hiding the xToolbar DIV tag. This xToolbar DIV tag allows the FCKEditor toolbar strip to sit at the very top of the HTML page, so to the user it appears like a normal text editor.
Then, each instance of the FCKeditor control shares this common text editor toolbar at the top fo the web page - at least that's the way it works in a plain HTML page...
What I see is a moment where the SmartClient interface appears, followed by what seems like a different page that only shows the FCKeditor (and then I can't launch the javascript:isc.showConsole() to see what happened).
Any ideas / suggestions / examples for integrating a 3rd party control with SC like this?
Rick
Comment