Skip to content

Further Customization of the RadEditor Image Manager

May 26, 2010

Removing the preview pane toolbar buttons is simple enough. But what if you want to get rid of the New Folder option, or take away certain elements from the Properties tab? That’s a little more complicated. (See my previous entry about editing the RadEditor Dialogs if you haven’t already.)

Removing the New Folder Option

Telerik actually has a great article about this. I’ll repeat their instructions here. Inside EditorDialogs\FileBrowser.ascx, find the tag. Simply add the property EnableCreateNewFolder="false" and the New Folder button will disappear from the file browser.

Removing Properties from Properties

These properties are all contained within EditorDialogs\SetImageProperties.ascx. What you’re looking for here is a document.write() of a term pretty similar to the property name in the dialog. In the table below, you’ll find the document.write() parameter and the line number of the corresponding
tag (more on this later).

Property document.write(); Parameter Line
Image Width/Height localization[“Width”], localization[“Height”] 720
Border Color localization[“BorderColor”] 768
Border Width localization[“BorderWidth”] 782
ALT Text localization[“ImageAltText”] 796
Long Description localization[“ImageLongDesc”] 810
Image Alignment localization[“ImageAlignment”] 824
Margins localization[“Margin”], localization[“Top”], localization[“Right”], localization[“Bottom”], localization[“Left”] 852
CSS Class localization[“CssClass”] 907

To hide any of these options, simply append style="display: none" to the <tr> tag on the indicated line. If you try this and it doesn’t work, or there isn’t a <tr> tag on that line, it’s probably because your SetImageProperties.ascx file is a little bit different than mine. In that case, just search the file for document.write(localization["ImageAlignment"]), for example, and find the containing <tr> to apply the style to.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: