TinyMCE in an EPiServer template page

In this project I’m working in at the moment we are developing an intranet based on EPiServer Relate. Currently in phase 2 of the development we are going to add the possibility for the users to blog about work etc on the intranet. If you look at the blog template in the Relate templates it’s kind of stripped of the possibilities to format the entered text etc. Nowadays EPiServer comes with TinyMCE so we placed an editor in the page with the following initialization:

tinyMCE.init({
mode: "specific_textareas",
editor_selector:"entryEditor",
theme: "advanced",
skin:"epi-light",
plugins:"epilink,table,media,advimage,epifilebrowser,paste",
theme_advanced_toolbar_location: "top",
theme_advanced_toolbar_align: "left",
theme_advanced_statausbar_location: "bottom",
theme_advanced_buttons1: "epilink,unlink,separator,image,media,separator,cut,copy,paste,pastetext,separator,tablecontrols",
theme_advanced_buttons2: "bold,italic,underline,separator,justifyleft,justifycenter,justifyright,separator,bullist,numlist,hr,separator,formatselect,separator,styleselect,separator,visualaid,fullscreen",
theme_advanced_buttons3:"",
theme_advanced_resizing: true,
content_css: "tinymce.css,editor.css",
theme_advanced_blockformats: "p,h2,h3",
width: '448',
height: '400'
})

which is a pretty standard editor and gives us an editor looking like this:

TinyMCE editor

There are a couple of EPiServer specific plugins added epilink and epifilebrowser. Epilink makes it possible for the user to create links to pages with the help of EPiServer page browser. Epifilebrowser on the other hand handles the functionality that inspired my to write this post, since that was the thing I couldn’t find out how to do.

Epifilebrowser is a non-visual TinyMCE plugin that adds a button in for example the image popup so you can use the EPiServer file browser for choosing your images.

Filebrowser button in image popup

The problem after this is that now we want to get the imagegallery of the blog to show up in the file browser, and I’ll come back to that when I have got the virtualpathprovider for that up and running.

About mathias

.Net system developer working mainly with CMS and then foremost with EPiServer. Other areas of interest are jQuery and writting plugins. Otherwise also interested in photography and then playing with my Nikon D70.
This entry was posted in CMS, Community, EPiServer, Tips and tagged , . Bookmark the permalink.