Add trimming spaces for text field

You can configure Sitefinity CMS to trim the spaces before and after the text entered in the text field. The spaces are trimmed from the text when you move the focus out of the field.

You can configure to trim spaces in any field.

Following is an example of how to enable the character counter on the Title field of the Edit dialog of the News module:

  1. Click Administration » Settings » Advanced.
  2. In the tree in the left, click News » Controls » NewsBackend » Views » NewsBackendEdit » Sections » MainSection » Fields » Title.
  3. Select TrimSpaces checkbox.
  4. Click Save Changes button.

If you click Content » News and choose to edit a news item and in the Title field, you enter some text with spaces before and after the actual value, when you leave the field the extra spaces are trimmed.

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?