Eloquence JDLG contact contact

JDLG object and attribute reference:
HtmlView class

  Document revision: 2023-02-22
Refers to JDLG version: 2.0.16


The HtmlView class implements a viewer which allows to display HTML or plain text content in a Dialog.

The HtmlView content may be explicitly set, or an URL may be specified to load a document.

When using hyperlinks in HTML content, the special eloq: URL is recognized to submit a rule value to the program.

The following eloq: URL syntax options are supported:


The optional RULE is a numeric value, specifying the rule value to be returned to the program, along with the path of the HtmlView object. If omitted, the default rule value is used.

The optional LINKFRAGMENT is a user-defined value which may be queried using the lastlinkfragment attribute after the eloq: URL was submitted.

For example:

<a href="eloq:">Click here to submit
    the default HtmlView rule value to the program</a>

<a href="eloq:/sunday">Same as above, the
    lastlinkfragment attribute will return "sunday"</a>

<a href="eloq:2805">Click here to submit
    the rule value 2805 to the program</a>

<a href="eloq:2805/monday">Same as above, the
    lastlinkfragment attribute will return "monday"</a>

Note: The HtmlView implementation uses a Java JEditorPane object, which provides only limited HTML 3.2 support. In particular, CSS or JavaScript are not supported.

add : string, set
Used to append the specified text to the content.
border : integer, get/set
By default, an HtmlView object displays a line border around its scroll pane, plus a white border around the HTML body area. This is equivalent to setting the border attribute to 2.

To disable one or both of these borders, the values below are supported:
0  no border
1  line border around scroll pane
2 (default)  like 1, plus white border around HTML body area

class : string, get
Returns "HTMLView".
clear : integer or string, set
Deletes the content. The argument is ignored.
content : string, get/set
Used to get or set the content. When set, the URL is cleared. Before setting the content, the mime type should be set (see below).
lastlinkfragment : string, get
Used to query the LINKFRAGMENT of the last rule submission (see above). An empty string is returned if the submitted eloq: URL does not specify a LINKFRAGMENT.
mimetype : string, get/set
Specifies the mime type to be assumed when the content is set.

Possible values are:

The default value is "text/html".

rule : integer, get/set
Specifies the default rule value to be returned to the program, along with the path of the HtmlView object, when an eloq: URL is submitted which does not specify a RULE value (see above).

The default rule value is zero.

See also the documentation of the common rule attribute.

url : string, get/set
Specifies the URL referring to a document. When set, the document is loaded during the next DLG DO or DLG DRAW and the content is replaced.

If a relative URL is specified, the value of the Application.baseurl or System.baseurl attribute or eloquence.config.baseurl configuration property is prepended.

The default value is empty.

  Privacy | Webmaster | Terms of use | Impressum Revision: 2023-02-22  
  Copyright © 1995-2021 Marxmeier Software AG