Skip to main content

Create a custom CSS style in a web form

Abstract

Customize the appearance of your web forms by creating custom CSS styles.

The Web Forms for Marketers module contains CSS styles that you can apply to form fields. Every field type has a default CSS style that is applied to it. You can also create custom CSS styles.

To create a custom CSS style:

  1. In the Website\sitecore modules\Shell\Web Forms for Marketers\Themes\ folder, in the custom.css file, define a new CSS style.

    D517BFFCCF7F40BAA5038FF7F5DCD671.png
  2. In the Content Editor, navigate to the sitecore/System/Modules/Web Forms for Marketers/Settings/Meta data/CSS Classes folder, and in the right pane click Extended List Item.

    43BC2C3D341F4C118FECBC9335FCA701.png
  3. In the Message dialog box, enter the name of the CSS style, for example Short Date, and then click OK.

  4. In the right pane, in the Value field, enter the name of the CSS style. Click Save.

    You can now apply your custom CSS style to any form field in the Form Designer.

    A3394FB2B2A84C74961AB98D2E892CB1.png