Creating a format area field
Format areas can contain both alpha-numeric values and formatting. A format area is a type of text field that allows for rich text formatting. You can configure several properties for a format area field.
About this task
- Document Type
- This setting determines the rules that are applied to this format area when Components based on this Schema are validated. You have the option of selecting Strict or Transitional document types.
- W3C Accessibility Level
- The Web Content Accessibility Guidelines (WCAG) setting that you choose shows or hides buttons for the various WCAG levels.
- Formatting features
-
Allow authors to format text by enabling formatting options that will be made available in a toolbar. You can configure the following settings:
- Allowed actions
-
Formatting actions that a user can perform on text within the format area. For example, if you disallow the Bold action, authors will not be able to make text bold. The allowed actions are, by default, constrained by the Document Type setting to ensure that the options available to authors corresponds with the accessibility level that you would like to apply to the format area. Default format settings for Transitional and Strict Document Types describes the default formatting settings for the Transitional and Strict Document Types.
- Allowed styles
-
Styles that a user can apply to text within a format area. These styles are configured using a cascading style sheet. For more information, see Format area configurations.
- Filtering XSLT
-
An XSLT that is applied when a user saves a Component based on this Schema. The XSLT applies transformation to the text in the Format Area. For example, you may use this option if your Page structure uses H1 formatting and you do not want the format area to apply the same formatting.
- Example
-
The following example shows an XSLT transformation that changes any h1 tags to h2 tags:
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" ><xsl:output method="xml"/> <xsl:template match="node()|@*"> <xsl:copy> <xsl:apply-templates select="@*|node()"/> </xsl:copy> </xsl:template> <xsl:template match="h1"> <h2><xsl:value-of select="."/></h2> </xsl:template> </xsl:stylesheet>