The Mighty Blog

Customizing the RadEditor in DotNetNuke

Aug 11

Written by:
8/11/2010  RssIcon

The default editor in DotNetNuke has been the RadEditor (by telerik) since version 05.02.00.  This editor is very robust and feature rich, including things like spell check, XHTML formatting, and many other advanced features.  It is considered by many to be the best web-based WYSIWYG HTML editor available.  I tend to agree.

With all of those features, it is very possible that some less advanced end-users might not enjoy the toolbar in its default state.  For example, you might want to remove functionality from the default toolbar.  Imagine removing advanced functionality like image maps, code validator, flash manager, etc. 

The editor allows you to customize this user experience very easily.  Unfortunately, there isn’t an option to do this through any of the administration of the website at this time.  You have to have file-level access to modify the files.

DotNetNuke ships with two tool configuration files.  They are:

  • ~/Providers/HtmlEditorProviders/Telerik/Config/ToolsDefault.xml
  • ~/Providers/HtmlEditorProviders/Telerik/Config/ToolsMinimal.xml

The editor uses the “ToolsDefault.xml” file, but you can easily change that by making a single change in the web.config file of your DNN site.

Find the line in your web.config that begins with <add name="TelerikEditorProvider" and change the value for the toolsFile attribute to the new XML tools file.  If you simply change from the ToolsDefault file to the ToolsMinimal file, you will see a significant difference in the two screen shots below.

DotNetNuke RadEditor using ToolsDefault.xml

DotNetNuke RadEditor using ToolsMinimal.xml 

Here is the line of code you’d be changing in the web.config, before and after.

<!-- BEFORE -->
<add name="TelerikEditorProvider" 
    type="DotNetNuke.HtmlEditor.TelerikEditorProvider.EditorProvider, DotNetNuke.HtmlEditor.TelerikEditorProvider" 
    providerPath="~/Providers/HtmlEditorProviders/Telerik/" 
    toolsFile="~/Providers/HtmlEditorProviders/Telerik/Config/ToolsDefault.xml" 
    configFile="~/Providers/HtmlEditorProviders/Telerik/Config/ConfigDefault.xml" 
    FilterHostExtensions="True" />
<!-- AFTER -->
<add name="TelerikEditorProvider" 
    type="DotNetNuke.HtmlEditor.TelerikEditorProvider.EditorProvider, DotNetNuke.HtmlEditor.TelerikEditorProvider" 
    providerPath="~/Providers/HtmlEditorProviders/Telerik/" 
    toolsFile="~/Providers/HtmlEditorProviders/Telerik/Config/ToolsMinimal.xml" 
    configFile="~/Providers/HtmlEditorProviders/Telerik/Config/ConfigDefault.xml" 
    FilterHostExtensions="True" />

Unfortunately, this change occurs for the entire installation of DNN right now.  So, plan how you minimize your toolbars accordingly.

Tags:
Categories: DotNetNuke

5 comment(s) so far...


Fix for Telerik RadEditor background issue

From v5.4 onwards DotNetNuke now uses the Telerik RADEditor. This editor replaces the FCK Editor which has been used in previous versions of DotNetNuke You can however still use the FCKEditor, it is s ...
# PixelNv Blog

By TrackBack on   8/13/2010
Gravatar

Re: Customizing the RadEditor in DotNetNuke

I had to localize RadEditor.Main.resx on a non-english site because the buttons for swiching from Design to Html mode were missing. Actually they were there but the text inside them was missing so you couldn't click on them and use them.

By Apartments Split on   8/18/2010
Gravatar

Re: Customizing the RadEditor in DotNetNuke

Hello

The dnnWerk RadEditor Provider is the solution for this issue. You can define different ToolsFile for each portal and also for different user rols: radeditor.codeplex.com

By Nicolo on   10/7/2010
Gravatar

Re: Customizing the RadEditor in DotNetNuke

@Nicolo: Nice tip! Thanks. :)

By Will on   10/7/2010
Gravatar

Re: Customizing the RadEditor in DotNetNuke

Excellent article and thx Nicolo for the tip

By safe on   11/9/2011

Your name:
Gravatar Preview
Your email:
(Optional) Email used only to show Gravatar.
Your website:
Title:
Comment:
Add Comment   Cancel 
Add to Technorati Favorites
Tweet about my blog
The opinions expressed here are the personal opinions of Will Strohl and do not necessarily represent the views and opinions of the DotNetNuke Corporation.
© Copyright 2004-2011 by Will Strohl. All rights reserved. Website Skinned By: Ralph Williams  Website Hosted By: Applied Innovations