Home>Support>Define css-classes within Visual editor

Define css-classes within Visual editor

Hi.

I’ve created a custom code block with text that is supposted to be formatted different within the visual editor. I’m trying to use css code that is not defined in the css-files of the wp-theme, and just put most / all of the needed css into the visual editor.

Thus I would like something like:

Headline

11111111
[email protected]
Employees

Department 2

[email protected]
222222
Emplyees dep 2

Where I would like to specify the css class of css-class-test1 within the visual editor, but that doen’t seems to work. Is it not possible to define classes in the visual editor under the widget style -> css-styles for the text within visual editor?

I’ve been able to use css that is not defined in a class, then the css code get used on the whole of the visual editor witch is not what I would like to accomplish.

This is our free support forum. Replies can take several days. If you need fast email support, please purchase a SiteOrigin Premium license.

  1. 6 years, 4 months ago Alex S
    Hi, I Work Here

    Hi Lhlied,

    Yes, it’s possible to use Widget Class to set a class that can be used to affect CSS added in that widget but you specifically need to target that to do this.

    If you do not wish to add the CSS externally, you should add it using a Custom HTML Widget rather than a Visual Editor.

Replies on this thread are closed. Please create a new thread if you have a question, or purchase a SiteOrigin Premium license if you need one-on-one email support.

Get The Most Out of SiteOrigin with SiteOrigin Premium

Find Out More