Question for folks concerning RTEs

I've decided to stop griping and finally add a rich text editor to BlogCFC (as an option of course). I'm looking into TinyMCE first with possible support for CKEditor as well. Some things have cropped up though that worry me.

First off - it is a bit difficult to get tinymce to ignore certain elements, like the more tag. I could simply add a new form field to the editor that would be used for all the text you would normally place before the more - I could name this the excerpt which is really what it is.

Code blocks are more worrisome though. I've looked at a Mango plugin for it, and while it isn't quite working for me, I assume I'll get it there eventually, but it begs the question:

If code blocks just don't work well in tinyMCE, would folks be ok with not being able to use tinyMCE? I figure it would still be a useful feature for BlogCFC users of a non-technical nature. They can use all the pretty buttons, make nice blog entries, etc. Those of us who normally need code blocks can handle HTML ourselves typically.

Thoughts?

Comments
Scott P's Gravatar I always just gone into source mode on the RTE and entered the html for code blocks.

Be nice if we just check box in admin to select using an RTE/which RTE. Now if only you had someone to help....
# Posted By Scott P | 1/5/10 7:06 AM
Raymond Camden's Gravatar Scott, it seems like when you do this (switch to source mode) you end up with a design mode where the code block is hidden. This to me is troublesome because at first glance, you may think there isn't a code block there. Does that make sense?
# Posted By Raymond Camden | 1/5/10 7:13 AM
Jeff Coughlin's Gravatar In your TinyMCE config settings add the following config:

Example1
content_css : "css/wysiwyg.css"

The path is a relative path, so change it accordingly (keep in mind that this is being called from a client-side application - javascript) and the css file can be named whatever you want (I like wysiwyg.css so that in case I end up with many css and xls files, I know exactly what this one is for). Then you can put simple styles in the css file to represent your site output. examples: code, p, h1, h2, table, etc.

I suggest giving the admin the ability to point to their own css file so that they can create a custom css file that represents the styles on their website (so what they see in the editor is "exactly" how it will appear on the website.

As a side note: I also like to add:

Example2
theme_advanced_styles : "Float left=floatLeft;Float right"

This allows me to have a couple simple styles that the content editors can apply to things like images (not overwhelming them with choices, but floating images is a common request). In the examples above, my classes are called .floatLeft and .floatRight, but the text the user sees in the dropdown is "Float left" and "Float right".

Also, you may want to customize the dropdown for blocks (so you can make things like "code" appear). Example:

Example3
theme_advanced_blockformats : "h1,h2,h3,h4,h5,h6,p,blockquote,address,dt,dd,code"
# Posted By Jeff Coughlin | 1/5/10 7:58 AM
Anthony Katgert's Gravatar Just curious, while you focus on text/code blocks, what are they supposed to do? what is there purpose and how do I use them.

PS

While tinyMCE is nice why not FCK editor and or what if I as a laymen person would want to implement either one of them myself. Can anyone share me a tutorial on how to do it on CFC blog
# Posted By Anthony Katgert | 1/5/10 10:01 AM
John Sieber's Gravatar Funny timing on your post. I have recently tried to get my own ColdFusion blog going using Mango over the last few days and ran into all of these issues with code blocks and TinyMCE. Personally, I think that an admin option is most appropriate so that blog administrators can decide which route to go. Earlier today I was looking at your ColdFusion Jedi blog and thinking about how nice the code blocks are on your site. I think I will be looking at Coldfish later this evening.
# Posted By John Sieber | 1/5/10 1:29 PM
John Sieber's Gravatar @Anthony Katgert

The code blocks are for posting sample code as content in the blog. They are treated differently as they are just meant for display and not execution. Hope that helps.
# Posted By John Sieber | 1/5/10 1:30 PM
John Sieber's Gravatar @Ray
Just curious as to why TinyMCE over CKEditor. I only really have experience with CKEditor so I'm just curious as to what I'm missing at on.
# Posted By John Sieber | 1/5/10 1:32 PM
Raymond Camden's Gravatar @John S: No particular reason, but I have slightly more experience with it.

@Anthony: John answered you. They are meant for code listings. This is described in the BlogCFC documentation.
# Posted By Raymond Camden | 1/5/10 2:38 PM
Andy Florino's Gravatar Hey Ray,
A few months ago I was tweaking (messing up) your textarea.cfm tag and implementing a slimmed down version of fckeditor. I believe that it's safe to use on the admin side cuz in theory you shouldn't have to worry about who is using the file manager (coldfusion 8 introduced some security holes i recall by using fckeditor as a built in rte). If i use the latest fckeditor and slim it down it integrates quite well and plays nice with your "more, code, and textblock" tags. If you're interested I could send it to ya..
# Posted By Andy Florino | 1/12/10 10:18 PM
Raymond Camden's Gravatar Sure, thanks.
# Posted By Raymond Camden | 1/13/10 1:06 AM
Josen Ruiseco's Gravatar Being that FCKEditor is built into ColdFusion, it would seem that is the likely candidate as an editor. I would (and have) favor it over TinyMCE for the BlogCFC app as it is VERY easy to integrate with CF8 and above, and fairly easy to integrate stand alone in the event one is on CF7.

That's my two cents...

Josen
# Posted By Josen Ruiseco | 1/16/10 5:40 AM
BlogCFC was created by Raymond Camden. This blog is running version 5.6.001.