Mar 262008
 

First off, let me just say that I don’t like any rich text editors very much. They are all a messy mix of HTML, JS, CSS, etc. There isn’t anything out there that is truly clean, feature rich and performs well. FCK has always been my least favorite, but I thought I would try 2.6 BETA and I was surprised at how much they added and updated things. This release has better dialogs and a smoother JavaScript experience. It is also less static and easier on AJAX apps.

Anyways, back to the point. JCatapult applications all use SiteMesh for templating and decoration. They actually have to because of our componentization model, otherwise components would be coupled to specific decoration or worse require tons of configuration (anyone interested in this concept contact me directly). Well, SiteMesh decorates your HTML using the GoF decorator pattern. Essentially the servlet container renders your JSPs or FTLs. That HTML is written out to the output stream, which SiteMesh has nicely intercepted being as it is a Filter. Once all the other Filters and servlets in your app complete, SiteMesh post processes the request, parse the HTML and decorates it. Very simple. The issue is that FCK editor uses HTML, JS, and CSS inside iframes in order to work its magic. Very ugly. What happens is that SiteMesh might end up decorating requests for FCK files. FCK REALLY doesn’t like this and usually you’ll end up with one of these symptoms:

  • No edit area, just the toolbar
  • Empty dialog boxes
  • Totally borked drop-shadows on dialogs

The quick fix, just tell SiteMesh to ignore FCK. You can accomplish that inside decorators.xml using an exclude:

  One Response to “FCKEditor is touchy (especially with SiteMesh)”

 Leave a Reply

(required)

(required)

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">