OpenWGA 7.10 - WebTML reference

WebTML tags » item

<tml:item editor ="text | textarea | textblock | number | rtf | date | file | upload | custom">


Specifies the editor to use for the item in the OpenWGA Content Manager.


As content editing in OpenWGA happens "in place" - i.e. the content is directly entered and maintained on the individual webpage - it is up to the WebTML code that displays an item to also specify an editor for it. This editor also determines the data type of which the entered item will be.

When a content author creates a draft copy of a document he sees little red markers on all displayed items where the WebTML code determined an editor for. When he clicks a marker the editor display switches to editor mode and allows the author to enter or change data for this item. The editing takes place at the exact position where the item is displayed on the webpage, so it is easy for the author to judge what his content will look like.

The author then stores his modifications by clicking on a "save" button or rejects them by clicking a "cancel" button, which both are presented on the "content management" panel of the Content Manager (or a little window helper popup if this is collapsed).

See examples for detail information about the editors provided.


  • text: Single line text input.
  • textarea: Multi line text input.
  • textblock: Simple RTF editor. Allows simple text format such line feeds.
  • number: Single line text input, value will be stored as number.
  • rtf: Rich Text Field. Allows the author to create extensive text formats. See Customizing RTF editor on how to customize rich text field settings.
  • date: Date input.
  • file oder upload: Allows the author to upload file attachments.
  • custom: Creates a custom editor (see example).



<tml:item name="_headline" editor="text"/> 

A standard HTML input field.


<tml:item name="_headline" editor="textarea"></tml:item>

A standard HTML textarea field for unformatted multiline text.


<tml:item name="_headline" editor="textblock">test</tml:item>

Creates a enhanced editor for unformatted multiline text.


<tml:item name="Body" editor="rtf"/>

Creates a so called "rich text field", allowing comfortable WYSIWYG input of formatted HTML code with many formatting options:

  • Text styles bold, italic, underline
  • Font style, size and color
  • Indent and outdent
  • Text orientation
  • Ordered and unordered lists
  • tables
  • Embedded links
  • Embedded images

The setting editor="rtf" implicitly also sets the encode attribute to "rtf", which will resolve some dynamic parts of the RTF to runtime values.

If an item that has been edited with the RTF editor should be put out by another <tml:item> tag that has no editor-Attribute, or any other type of tag, then the attribute encode="rtf" should be assigned to it manually so that these dynamic parts are also resolved on this output.


<tml:item name="_myDate" format="dd.MM.yyyy" editor="date"/>

Creates a standard HTML input field which will accept only date/time values in the given format (determined by the format attribute). The stored value will also be of data type "date".


<tml:item name="_myNumber" format="0.#" editor="number"/>

Creates a standard HTML input field which will accept only numeric values in the given format (determined by the format attribute). The stored value will also be of data type "number".


<tml:item name="fileName" editor="file" label="Click here to upload files"/>

Creates a file upload field. The uploaded file will be attached to the content document. The attribute "name", though needed, is not evaluated in this case.


<tml:item label="Custom Editor" name="Dummy" editor="custom">

  <table border="1">



      <td><tml:input type="text" name="title"/></td>




      <td><tml:input type="text" name="text"/></td>




      <td><tml:input type="textarea" name="comments">rows="4" cols="30"</tml:input></td>




Uses a custom WebTML form as editor. Use <tml:input> inside to define single input fields. On save all input fields will be stored to the content document just like this would be a <tml:form> in the context of this document.