views:

73

answers:

4

I am using Wordpress and I want site editors to be able to write html by hand (no wysiwyg). However, everyone knows that editing html in a textarea with no colorization or other code editor features is difficult. Does anyone know of a solution -- maybe a textarea replacement, browser extension, or the like?

There are plenty of wysiwyg editors, but I'm specifically looking for an in-browser code editor that handles HTML. It would be a bonus if it handled javascript and CSS as well.

+4  A: 

Have you considered using Markdown (as StackOverflow does) ?

In my opinion, it is very easy to write and format text using Markdown. It is easy to get started with WMD, which is a java-script only Markdown editor.

driis
This is a good idea. I was thinking they would edit minimal HTML elements but markdown would enforce that. I will look into it.
Pete
+2  A: 

Mozilla bespin is a javascript text editor that can be embedded.

cobbal
Trying bespin which even has a bookmarklet. Seems extremely limited right now and it can't word-wrap which makes it difficult when converting a textarea on the fly.
Pete
A: 

I'm quite fond of XStandard. It produces proper valid HTML (Only the XHTML varieties), has a realistic WYSIWYG editor with the option to also edit the source directly, and has a free version (which has been enough for uses I've put it to).

Jon Hanna
A: 

Duplicate of http://stackoverflow.com/questions/1505761/textarea-with-syntax-code-highlighting and http://stackoverflow.com/questions/1619167/textarea-that-can-do-syntax-highlighting-on-the-fly

From those threads, a list of in-browser html editors: http://en.wikipedia.org/wiki/Comparison_of_JavaScript-based_source_code_editors

EditArea, CodeMirror, CodePress, and Bespin all seem active and capable. Using WMD for markdown is another option.

Pete