A Form component is a layout component that positions components so that their labels and fields align horizontally. In general, the main content of the Form consists of input components (such as Textbox) and selection components (such as Choice). If a child component with a label attribute defined is placed inside the Form, the child component's label and field are aligned and sized based on the Form definitions. Within the Form, the label area can either be displayed on the start side of the field area or on a separate line above the field area.
This component consists of the following basic elements:
This component is commonly used on tablets and phones.
Appearance characteristics for this component.
Common behaviors for this component.
Usage guidelines for this component.
AMX sample code for this component.
<amx:outputText value="Sub-Section Title" styleClass="amx-text-sectiontitle"/>
<amx:panelFormLayout labelAlignment="start">
<amx:panelLabelAndMessage label="Name">
<amx:commandLink text="Jim Berney" action="editname"/>
</amx:panelLabelAndMessage>
<amx:panelLabelAndMessage label="Street Address">
<amx:commandLink text="123 Main Street" action="editaddr"/>
</amx:panelLabelAndMessage>
<amx:panelLabelAndMessage label="Phone">
<amx:outputText value="888-555-1212"/>
</amx:panelLabelAndMessage>
</amx:panelFormLayout>
<amx:outputText value="Sub-Section Title" styleClass="amx-text-sectiontitle"/>
<amx:panelFormLayout labelAlignment="start">
<amx:panelLabelAndMessage label="Type">
<amx:commandLink text="Personal" action="edittype"/>
</amx:panelLabelAndMessage>
<amx:panelLabelAndMessage label="Anniversary">
<amx:outputText value="November 22, 2005"/>
</amx:panelLabelAndMessage>
</amx:panelFormLayout>
<amx:panelFormLayout labelAlignment="start">
<amx:panelLabelAndMessage label="Date Created">
<amx:outputText value="June 20, 2011"/>
</amx:panelLabelAndMessage>
</amx:panelFormLayout>
Fig 1. iOS Form - Labels Start Aligned
Fig 2. Android Form - Labels Start Aligned