Feldtyp Text-Formular

From Joomla! Documentation

Revision as of 15:44, 13 April 2019 by Dimkk (talk | contribs) (Created page with "* Beschreibung''''' (optional) (übersetzbar) ist der Text, der als Tooltip als Mouse-over Effekt über die Dropdown-Box angezeigt wird.")

The text form field type provides a text box for data entry. If the field has a value saved, this value is displayed when the page is first loaded. If not, the default value (if any) is selected.

  • type (mandatory) must be text.
  • name (obligatorisch) ist der eindeutige Name des Feldes.
  • label (obligatorisch) (übersetzbar) ist der beschreibende Titel des Feldes.
  • size' (optional) ist die Breite des Textfeldes in (alphanumerischen) Zeichen. Wird es versäumt, diesen Wert zu setzen, gilt die Browsereinstellung. Dieser Wert begrenzt nicht die Menge der Zeichen, die eingegeben werden können.
  • maxlength' (optional) begrenzt die Anzahl der Zeichen, die eingegeben werden können.
default' (optional) (nicht übersetzbar) ist der Standardwert.
  • Beschreibung (optional) (übersetzbar) ist der Text, der als Tooltip als Mouse-over Effekt über die Dropdown-Box angezeigt wird.
  • class (optional) is a CSS class name for the HTML form field. If omitted this will default to 'text_area'.
  • readonly (optional) The field cannot be changed and will automatically inherit the default value. (Possible values: "true", "1", "readonly" to set to true)
  • disabled (optional) The field cannot be changed and will automatically inherit the default value - it will also not submit. (Possible values: "true", "1", "readonly" to set to true)
  • required (optional) The field must be filled before submitting the form. (Possible values: "true", "1", "readonly" to set to true)
  • filter (optional) allow the system to save certain html tags or raw data.
  • message (optional) The error message that will be displayed instead of the default message.
  • hint (optional) The text displayed in the html placeholder element, usually a lighter coloured hint displayed inside an blank field.
  • inputtype (optional) Set the HTML5 input type
  • pattern (optional) A regular expression pattern to use for validation.

Example XML field definition:

<field name="mytextvalue" type="text" default="Some text" label="Enter some text" description="" size="10" />

Use the integer filter to ensure that letters types get stripped when the form is processed.

<field name="myintvalue" type="text" default="8" label="Enter some text" description="Enter some description" filter="integer" />

Use the raw filter to ensure that html code is preserved when the form is processed.

<field name="myhtmlvalue" type="text" default="" label="Enter some text" description="Enter some description" filter="raw" />

See also