Sitefinity CMS MVC widgets use fields to build their views both for list and detail mode. Depending on your requirements, you can customize these fields by changing the view of a specific field either in a single dynamic content MVC widget or in all dynamic content MVC widgets. In addition to changing the view of a field, you may want to add additional logic to the field. In this case, we recommend to to create custom fields. The following article explains how to create custom field that inherits the LongTextAreaField and register it using dependency injection.
Perform the following:
The code above registers new template for the custom field by overriding the GetTemplatePath method.
The ObjectFactory is a special class in Sitefinity CMS that wraps the IUnityContainer, part of the Microsoft Practices Unity Application Block. You use the Unity Application Block for inversion of control pattern.
Back To Top
To submit feedback, please update your cookie settings and allow the usage of Functional cookies.
Your feedback about this content is important
Copyright © 2023 Progress Software Corporation and/or its subsidiaries or affiliates.
All Rights Reserved.
Progress, Telerik, Ipswitch, and certain product names used herein are trademarks or registered trademarks of Progress Software Corporation and/or one of its subsidiaries or affiliates in the U.S. and/or other countries. See Trademarks for appropriate markings.
Powered by Progress Sitefinity