Try our conversational search powered by Generative AI!

EPiServer custom style in Editor


I've added some custom class styles into a css file for the editor to use, these new styles are picked up correctly when I edit some content so this portion is working.

There seems to be a wierd issue though, where instead of changing the class name of an element it keeps adding the new style to the end of the element.

My styles in dropdown: Red, Amber, Green

My Custom CSS: {ChangeElementType: true; EditMenuTitle: Service Status Styles; EditMenuName: Green ; background: url(../img/green-dot.png) left center no-repeat; }

h4.amber {ChangeElementType: true; EditMenuName: Amber ; background: url(../img/amber-dot.png) left center no-repeat; } {ChangeElementType: true; EditMenuName: Red ; background: url(../img/red-dot.png) left center no-repeat; }

In the editor after changing the CSS style from the drop down: <h4 class="amber red green">Test Header</h4>


Have i missed something really obvious here?

Mar 22, 2012 10:43

Hi Chris,
this is not an error, it is actually how it is supposed to work - while elements get replaced, the classes get applied. You can use the "remove formatting" button to easily remove existing styles.

Mar 23, 2012 13:38

I just wanted to add that you can remove formatting by clicking the "Styles" (marked in grey) word in the styles drop down. Just a tip if you don't want to add the "remove formatting" button.

Mar 23, 2012 14:23
This thread is locked and should be used for reference only. Please use the Episerver CMS 7 and earlier versions forum to open new discussions.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.