Adding a label component for accessibility

The Label component associates an accessibility label with a Faces component. Labels are often used by screen readers and other similar programs.

Follow these steps to add an accessibility label to most Faces components.

Note: When you add a label to a page, you add both the label and an output text component.

  1. Drag a Label component from the palette and drop it on top of the component you want to label. Make sure to drop it on top of the first half of the component so that it adds the label component in front of the component you're dropping on. The Configure Label dialog opens.

  2. Enter text for the label and click OK. The label component is inserted before the target component. You are prompted to add an output text component If you just want an accessibility label, do not enter a text label when prompted. If you want a text label before the control in addition to an accessibility label, enter a text label at the prompt.

  3. Specify additional attributes for the label component in the Properties view for the label. (Make sure that you select the label component and not the component that was created right next to it.)

  4. You can also link a component with its label manually.

    1. Note the ID of the component for which you want to add a label. (See the Properties views of most components for the ID.)

    2. Drag a Label component from the palette to a blank area of the Faces JSP page.

    3. In the Properties view for the label, click

      ID to label and select the ID of the component you want to label. The label is now associated with the component.

Note that you can automatically create labels in other ways. For example, when you create controls to display a record (when you drag a relational record to a page), there is an option to automatically create labels for all controls. This option is on the Advanced tab of the Option dialog. If you are creating a display or input form by dragging a relational record to a page, this is the easiest way to add labels for all your controls.