I'm working on standardizing textarea input/formatting in OpenACS.
The default input format, I think, should be like what MovableType has, namely HTML input where the software can automatically insert <p>'s, <br>', and 's for you. it could also make links out of URLs and emails. So essentially, this is the current plaintext format, except we don't quote HTML tags for you.
It's really convenient to be able to use simple HTML formatting, but it's really annoying to have to insert your own paragraph and line breaks.
I still think that keeping the plaintext format is nice for posts like this, where you want to write HTML tags that should be shown literatly.
Also, preformatted text probably makes sense. And finally, a "raw HTML" format also makes sense, for when you're copy-pasting stuff from some other source.
Finally, I've added some simple [B], [I], [U], and [URL] buttons which will wrap your current selection in the relevant tags. This is ripped from MovableType (we might need to create our own version of this, though this code is floating around the net in several places).
This only works in IE, though, I haven't been able to figure out how to make it work in Mozilla or other browsers. If there are any Javascript gurus out there, any help would be much appreciated.
I also considered coming up with a Wiki-style 'structured' input language, but Carl convinced me that we'd never manage to teach people yet another rich text formatting language, that it's better to just stick with HTML and add a few buttons to make it easier to use.
Q: Do you people agree that this input format (HTML with <p>, <br>, , and email/URL->link translation) is the optimal format?
Q: How do we label these formats? We could keep HTML/Plaintext/Preformatted, and add two check boxes "Preserve line breaks" and "Make links out of emails and URLs", but that's really long and convoluted.
We could also call them HTML, Raw HTML, Text, and Preformatted. Is that better? Or "Rich HTML"/"Raw HTML"? How would we explain the difference to people?
Is there any need to be able to turn on/off line breaking and making links out of emails and URLs separately from each other?
If you want to play with this, try here:
http://oacs-pg.cph01.collaboraid.net/bug-tracker/bug?bug%5fnumber=12
Register to try.
/Lars