Advanced Customization > Info*Engine User’s Guide > Display Webject Reference > Display Webjects for HTML > Display-Value
  
Display-Value
DESCRIPTION
Displays the value of an attribute, or set of attributes, of an Info*Engine group as HTML elements.
SYNTAX
<ie:webject name="Display-Value" type="DSP">
  <ie:param name="ATTRIBUTE" data="attributes"/>
  <ie:param name="GROUP_IN" data="group_name"/>
  <ie:param name="NAME" data="name"/>
  <ie:param name="POST_TABLE_TEXT" data="text"/>
  <ie:param name="PRE_TABLE_TEXT" data="text"/>
  <ie:param name="PROMPT" data="somecomment"/>
  <ie:param name="SIZE" data="[columnsXrows
                                 |windowsize/maxsize | size]"/>
  <ie:param name="TYPE" data="[HTML | RADIO | FILE | PLAIN |
              TEXT | TEXTAREA| HIDDEN | CHECKBOX | PASSWORD]"/>
  <ie:param name="UNDEFINED" data="somevalue"/>
</ie:webject>
PARAMETERS
Required
Select
Optional
ATTRIBUTE
NAME
GROUP_IN
PROMPT
PRE_TABLE_TEXT
SIZE
POST_TABLE_TEXT
TYPE
UNDEFINED
ATTRIBUTE
Identifies the name of the database attributes to display. The order in which the attributes are specified determines the order in which they are displayed. Refer to the table in the TYPE parameter description for the TYPE values with which this parameter can be used. Multiple values can be specified for this parameter. This parameter is required.
GROUP_IN
Identifies the name of the group to be used as an input source. The group can be a VDB group or a Context group. For further information about groups, see Info*Engine Data Management.
The default for this parameter is to use the last group defined in the VDB. This parameter is optional.
NAME
Assigns a form name to the generated FORM element. You can refer to this name in the next JSP page to supply a value (such as within a WHERE clause). The default for this parameter is the attribute name of the database value displayed. Refer to the table in the TYPE parameter description for the TYPE values with which this parameter can be used.
POST_TABLE_TEXT
Specifies the text or HTML generated after each group of objects. The default for this parameter is "". This parameter is optional.
PRE_TABLE_TEXT
Specifies the text or HTML generated before each group of objects. The default for this parameter is "". This parameter is optional.
PROMPT
Specifies a descriptive string of text that you want to display to the left of the attribute value. The default for this parameter is the attribute name. Multiple values can be specified for this parameter. Refer to the table in the TYPE parameter description for the TYPE values with which this parameter can be used.
SIZE
Sets the length of the text field used to display the attribute value.
If the SIZE parameter is used to specify the size of a TEXTAREA in the TYPE parameter, then the value of the SIZE parameter must be stated using the format data="columnsXrows" (for example, data="10x4").
If you use the SIZE parameter to limit the maximum length of a text input field, such a TEXT or PASSWORD in the TYPE parameter, then you must specify the value using the format data="windowsize/maximumsize", where the windowsize is the maximum number of characters to display for that element and the maximumsize is the maximum number of characters to accept for that element. For example, assume that your windowsize is 10 and your maximumsize is 20; the resulting parameter would be:
<ie:param name="SIZE" data="10/20"/>
Refer to the table in the TYPE parameter description for the TYPE values with which this parameter can be used. Multiple values can be specified for this parameter. The default for this parameter is 11 characters.
TYPE
Specifies how to display the value of the ATTRIBUTE parameter. Valid values are HTML, PLAIN, TEXT, TEXTAREA, HIDDEN, and PASSWORD:
CHECKBOX – Displays data with a checkbox to the left. Must be used in conjunction with a form.
FILE – Allows the user to select files in order to submit their contents with a form. Must be used in conjunction with a form.
HIDDEN – Creates a hidden form element which displays nothing, but passes the value of the attribute. Must be used in conjunction with a form.
HTML – Encodes an output string in HTML.
PASSWORD – Similar to TEXT. However, what is typed is not visible to the user. Must be used in conjunction with a form.
PLAIN – Displays an attribute value as text that cannot be edited.
RADIO – Displays data with a radio button to the left. Radio buttons work like checkboxes; however radio buttons may be mutually exclusive. Must be used in conjunction with a form.
TEXT – Displays an attribute value in a text box and is editable. Must be used in conjunction with a form.
TEXTAREA – Displays multiple rows. However, the number of rows and columns must be specified in the SIZE parameter. TEXTAREA must be used in conjunction with a form.
The default for this optional parameter is PLAIN.
The following table shows which parameters are usable depending on the TYPE:
ATTRIBUTE
NAME
PROMPT
SIZE
CHECKBOX
X
X
FILE
X
HIDDEN
X
X
HTML
X
PASSWORD
X
X
X
X
RADIO
X
X
TEXT
X
X
X
X
TEXTAREA
X
X
X
UNDEFINED
Sets the value to display for an undefined value. An undefined value is either a nonexistent attribute or an attribute that has a null value. An attribute containing an empty string ("") is not interpreted as being undefined. The default for this parameter is "". This parameter is optional.
EXAMPLES
The following Display-Value webject examples assume an input group containing multiple elements; each with a name, address and email attribute value:
* 
The FORM element is not automatically generated by this webject. To display the lists correctly, include the <FORM> and </FORM> tags as shown in the examples.
DEFAULT DISPLAY OF MULTIPLE ATTRIBUTES
Webject
<form>
<ie:webject name="Display-Value" type="DSP">
  <ie:param name="GROUP_IN" data="createdgroup"/>
  <ie:param name="ATTRIBUTE" data="EMAIL,NAME" delim=","/>
  <ie:param name="UNDEFINED" data="N/A"/>
</ie:webject>
</form>
Output
Generated HTML
<form>
<b>EMAIL</b>:sjohnson@somewhere.com<b>NAME</b>:Sam Johnson
<b>EMAIL</b>:handerson@somewhere.com<b>NAME</b>:Harvy Anderson
<b>EMAIL</b>:N/A<b>NAME</b>:James O'Connor
<b>EMAIL</b>:hhampton@somewhere.com<b>NAME</b>:Harvey Hampton
</form>
MULTIPLE ATTRIBUTES WITH PROMPTS AND NON-DEFAULT NAMES
The following example displays the NAME and ADDRESS attributes after their PROMPT value.
Webject
<form>
<ie:webject name="Display-Value" type="DSP">
  <ie:param name="ATTRIBUTE" data="NAME,ADDRESS" delim=","/>
  <ie:param name="PROMPT"
                   data="Common Name: , Address: " delim=","/>
  <ie:param name="TYPE" data="PLAIN"/>
</ie:webject>
</form>
Output
Generated HTML
<form>
<pre>
NamePrompt <input type="text" name="NameField" value="Sam
            Johnson" size="20">AddressPrompt <input type="text"
           name="AddressField" value="1234 Main St." size="20">
NamePrompt <input type="text" name="NameField" value="Harvy
           Anderson" size="20">AddressPrompt <input type="text"
          name="AddressField" value="1234 Amber St." size="20">
NamePrompt <input type="text" name="NameField" value="James
           O'Connor" size="20">AddressPrompt <input type="text"
            name="AddressField" value="775 Main St." size="20">
NamePrompt <input type="text" name="NameField" value="Harvey
            Hampton" size="20">AddressPrompt <input type="text"
            name="AddressField" value="775 Main St." size="20">
</pre>
</form>
SINGLE ATTRIBUTE, TYPE=PLAIN
Webject
<form>
ie:webject name="Display-Value" type="DSP">
  <ie:param name="ATTRIBUTE" data="NAME"/>
  <ie:param name="PROMPT" data=""/>
  <ie:param name="TYPE" data="PLAIN"/>
</ie:webject>
</form>
Output
Generated HTML
<form>
Sam JohnsonHarvy AndersonJames O'ConnorHarvey Hampton
</form>
MULTIPLE ATTRIBUTES WITH PROMPTS, DEFAULT NAMES, AND TYPE=TEXT
Webject
<form>
<ie:webject name="Display-Value" type="DSP">
  <ie:param name="ATTRIBUTE" data="NAME,ADDRESS" delim=","/>
  <ie:param name="PROMPT" data="EmployeNAME - ,
                                EmployeeAddress - " delim=","/>
  <ie:param name="TYPE" data="text"/>
  <ie:param name="SIZE" data="20"/>
  <ie:param name="CELLPADDING" data="5"/>
</ie:webject>
</form>
Output
MULTIPLE ATTRIBUTES WITH PROMPTS, SPECIFIED NAMES, AND TYPE=TEXT
Webject
<form>
<ie:webject name="Display-Value" type="DSP">
  <ie:param name="ATTRIBUTE" data="NAME,ADDRESS" delim=","/>
  <ie:param name="NAME" data="NameField,
                                      AddressField" delim=","/>
  <ie:param name="PROMPT" data="NamePrompt ,
                                    AddressPrompt " delim=","/>
  <ie:param name="TYPE" data="text"/>
  <ie:param name="SIZE" data="20/20"/>
  <ie:param name="CELLPADDING" data="5"/>
</ie:webject>
<form>
Output
MULTIPLE ATTRIBUTES WITH PROMPTS, SPECIFIED NAMES, AND MULTIPLE TYPE VALUES
Webject
<form>
<ie:webject name="Display-Value" type="DSP">
  <ie:param name="ATTRIBUTE" data="NAME,ADDRESS" delim=","/>
  <ie:param name="NAME" data="NameField,AddressField"
                                                    delim=","/>
  <ie:param name="PROMPT" data="NamePrompt , AddresstPrompt "
                                                    delim=","/>
  <ie:param name="TYPE" data="text,password" delim=","/>
  <ie:param name="SIZE" data="20/20,20/20"/>
  <ie:param name="CELLPADDING" data="5"/>
</ie:webject>
</form>
Output
MULTIPLE ATTRIBUTES WITH PROMPTS AND SPECIFIED NAMES, TYPE=CHECKBOX
Webject
<form>
<ie:webject name="Display-Value" type="DSP">
  <ie:param name="ATTRIBUTE" data="NAME,ADDRESS" delim=","/>
  <ie:param name="NAME" data="NameField,DepartmentField"
                                                    delim=","/>
  <ie:param name="PROMPT" data="NamePrompt , DepartmentPrompt "
                                                    delim=","/>
  <ie:param name="TYPE" data="checkbox"/>
  <ie:param name="SIZE" data="20"/>
  <ie:param name="CELLPADDING" data="5"/>
</ie:webject>
</form>
Output
MULTIPLE ATTRIBUTES WITH PROMPTS, TYPE=TEXTAREA
Webject
<form>
<ie:webject name="Display-Value" type="DSP">
  <ie:param name="ATTRIBUTE" data="NAME"/>
  <ie:param name="ATTRIBUTE" data="ADDRESS"/>
  <ie:param name="NAME" data="NameField,AddressField"
                                                    delim=","/>
  <ie:param name="PROMPT" data="NamePrompt = ,AddressPrompt = "
                                                    delim=","/>
  <ie:param name="TYPE" data="TEXTAREA"/>
  <ie:param name="SIZE" data="20x4"/>
  <ie:param name="CELLPADDING" data="5"/>
</ie:webject>
</form>
Output
SINGLE ATTRIBUTE WITH PROMPT, TYPE=PASSWORD
Webject
<form>
<ie:webject name="Display-Value" type="DSP">
  <ie:param name="ATTRIBUTE" data="NAME"/>
  <ie:param name="TYPE" data="password"/>
  <ie:param name="PROMPT" data="Password Prompt: "/>
  <ie:param name="SIZE" data="40"/>
</ie:webject>
</form>
Output