Choices custom field

Static content types

Static content types come out of the box with Sitefinity CMS, such as Pages, Blogs, News, and so on.

To add a custom field to a content item, perform the following:

  1. Perform procedure Create custom fields » Step 1 to Step 5.
  2. In the Type dropdown box, select Choices.
  3. Enter a name for the field.
    The name of the field is different from its label. The field's name serves as reference for that field in the backend.
  4. If you select the Multiple choices can be selected checkbox, then the field becomes a checkbox field. If you leave it deselected - it is a radio buttons field or a dropdown box field, depending on the interface widget you select in the next step.
  5. In the Interface widget for entering data dropdown box, you select the widget which the creator or editor of the content item or page will use to complete the field.
    The default widgets are Radio buttons or Dropdown list. If you have selected Multiple choices can be selected checkbox, the default widget is Checkboxes. All widgets display a list of choices with labels and instructions.
  6. Expand the Advanced section if you want to change the database and the SQL database type of the custom field, if you want to specify the name of the column of the database table where the custom field is added, and if you want to make additional advanced settings.
    If the Allow empty values checkbox is selected, the field is not required and can be left empty. If you deselect it, the field becomes mandatory.
  7. Click Continue.
    A window appears where you must configure the appearance of the custom field, such as labels and instructions.

Label and texts

On this tab, perform the following:

  1. In the Label (Question) input field enter the label of the custom field.
    For example, enter Select your favorite ice cream.
  2. In the Label column, enter all the choices that you require.
    You can add or delete choices.
  3. In the Value column, enter the unique name of each choice. It is not visible to users in the interface.

    NOTE: Value is the unique name of each choice. It is not visible by users in the interface.

  4. When finished, click Done.
    The new field appears in the list of custom fields for the respective module.
    If you want to delete a custom field, click .

Save your changes.

Dynamic content types

Dynamic content types are the ones you create using the Module Builder.

To add a custom field to a content item, perform the following:

  1. Perform procedure Create custom fields » Step 1 to Step 5.
  2. In the Type dropdown box, select Choices.
  3. Enter a name for the field.
    The name of the field is different from its label. The field's name serves as a reference for that field in the backend.
  4. If you select Multiple choices can be selected checkbox, then the field becomes a checkbox field. If you leave it deselected – it is a radio buttons field or a dropdown box field, depending on the interface widget you select in the next step.
  5. In the Interface widget for entering data dropdown box, you select the widget which the creator or editor of the content item or page will use to complete the field.
    The default widgets are Radio buttons or Dropdown list. If you have selected Multiple choices can be selected checkbox, the default widget is Checkboxes. All widgets display a list of choices with labels and instructions.
  6. Expand the Advanced section if you want to change the database and the SQL database type of the custom field, if you want to specify the name of the column of the database table where the custom field is added, and if you want to make additional advanced settings.

    If the Allow empty values checkbox is selected, the field is not required and can be left empty. If you deselect it, the field becomes mandatory.

  7. Click Continue.
    A window appears where you must configure the appearance of the custom field, such as labels and instructions.

General

On this tab, perform the following:

  1. In the Label (Question) input field, enter the label of the custom field.
    For example, enter Select your favorite ice cream.
  2. In the Label column under Choices, enter all the choices that you require.
    You can add or delete choices
  3. In the Value column, enter the unique name of each choice. It is not visible to users in the interface.
  4. When finished, click Done.
    The new field appears in the list of custom fields for the respective module.
    If you want to delete a custom field, click .
  5. Save your changes.

Increase your Sitefinity skills by signing up for our free trainings. Get Sitefinity-certified at Progress Education Community to boost your credentials.

Get started with Integration Hub | Sitefinity Cloud | Sitefinity SaaS

This free lesson teaches administrators, marketers, and other business professionals how to use the Integration hub service to create automated workflows between Sitefinity and other business systems.

Web Security for Sitefinity Administrators

This free lesson teaches administrators the basics about protecting yor Sitefinity instance and its sites from external threats. Configure HTTPS, SSL, allow lists for trusted sites, and cookie security, among others.

Foundations of Sitefinity ASP.NET Core Development

The free on-demand video course teaches developers how to use Sitefinity .NET Core and leverage its decoupled architecture and new way of coding against the platform.

Was this article helpful?