0

Hi all.
Can anybody point me in the right direction as to how to implement the editor that opens up when I click Start new thread or post reply?

Also when displaying the replies how is the feature with syntax highlighting and indentation for the code snippets implemented ?

Thanks.

4
Contributors
8
Replies
9
Views
6 Years
Discussion Span
Last Post by Taywin
0

I've been using TinyMCE for a while. You need to have the library on your server side and include the library in the page. Don't forget the configuration in your javascript. Then you need to follow the format of a textarea element and it should automatically shows the editor for you.

0

I've been using TinyMCE for a while. You need to have the library on your server side and include the library in the page. Don't forget the configuration in your javascript. Then you need to follow the format of a textarea element and it should automatically shows the editor for you.

Okay. So I've got TinyMCE show up in the text area and the textual data gets inserted in the database. Now, when I retrieve the data from the database during display how do I make it so that the display is formatted by SyntaxHighlighter?

0

Sorry, I don't use SyntaxHighlighter. My codes are usually copy righted to the company I am working for. However, you may look at the SyntaxHighlighter demo and view its page source. From what I understand, you need a 'pre' tag and also load the library to the page. Then, you add the html-script property to the 'pre' tag. That's my guess.

0

Sorry, I don't use SyntaxHighlighter. My codes are usually copy righted to the company I am working for. However, you may look at the SyntaxHighlighter demo and view its page source. From what I understand, you need a 'pre' tag and also load the library to the page. Then, you add the html-script property to the 'pre' tag. That's my guess.

So, that means if I want the content from TinyMCE to be formatted by SyntaxHighlighter while displaying, I will need to wrap the code contents within <pre></pre> tags. Will it pose any problems to TinyMCE to provide explicit HTML tags?

0

Free CKEditor

my company uses it, though we abbreviate it lovingly "fcked" But it works nicely for what we're doing, which is working with Word documents.

0

Hmm... If you want WYSIWYG 'editor' which also displays a code format at the same time, I doubt there is one for you. The reason is the HTML element property limitation. Though, you could create one but would not be as much pretty as you want. If you see this forum, it only 'display' the code in whatever its format, but it will display as a textarea when you do the editing. In other words, you can accept the input using a WYSIWYG editor on a textarea, and then display it out on pre tag afterward. No editing & displaying at the same time (similar to this website).

@Fortinbra
Yes, The editor you are talking about is called Fckeditor which is a legitimate name. It's been around for a long time too. Not sure whether it is before TinyMCE.

Edited by Taywin: n/a

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.