Since OpenCms 8 a resource type "Dynamic Function" has been introduced. This resource type makes it possible to drag and drop a dynamic content provided by a jsp directly into a containerpage of the website.
Use Case: A typical use case is extending the website by a search or a login functionality.
Example: In this demo example a simple date display is added to a box, which can be dropped in one of the side containers. The settings are used to set the format of the date. The locale is provided by a request parameter defined for the dynamic function.
How to use "Dynamic Function":
Additionally define the settings in the second tab directly in the XML content editor. Use the same options as inside the schema definition for the resource type.
Important note: The HTML output provided by the used JSP should be surrounded by a <div> tag, similar to the formatter jsp.