Rich text fields on the Web

You have the following options for defining how a rich text field displays on the Web:

  • The rich text field displays for editing within an HTML text area. This is the default behavior.
  • The rich text field displays using the editor applet, allowing for a broader range of editing options.
  • The rich text field displays using a JavaScript control, allowing for a broader range of editing options.

Displaying rich text in Web applications

When you are designing a Web application, the following options define how rich text displays in the browser:

  • "Using HTML" renders the control as HTML and is the default behavior.
  • "Using Java Applet" renders the control as an applet. This allows browser users to see mouse-over distinctions for items in the outline, including change of color to indicate a selected item, and see background items.
  • "Using Best Fit for OS" allows the Domino® Web server to render the control as it sees fit depending on the client browser.
  • "Using JavaScript Control" renders the control as JavaScript using the Dojo toolkit (see http://dojotoolkit.org). The benefits are similar to using an applet, but the Dojo-based mechanism uses standard HTML and CSS.

To specify how to display rich text

  1. Create a rich text field.
  2. Choose Design - Field Properties.
  3. On the Info tab, for "Web Access" select "Using HTML," "Using Java Applet," "Using Best Fit for OS," or "Using JavaScript Control."

Using the editor applet

Web users can do the following when using the editor applet in a rich text field:

  • Bold, underline, and italicize text
  • Change to Helvetica, Courier, or Times (fonts supported by the Java Development Kit (JDK), Release 1.0.2)
  • Change font size
  • Change font color
  • Align paragraphs (left, center, right)
  • Indent paragraphs
  • Use bulleted and numbered lists
  • Create links
  • Cut, copy, and paste text within the rich text field
    Note: Web users cannot paste text from outside the editor because of the limitations of the JDK, Release 1.0.2.
  • Enter international characters
    Note: Not all international characters can be displayed in the editor applet. The ability to display international characters depends on the fonts installed on the user's workstation and the version of the browser the user is working with. Most characters entered in the editor will be correctly transferred to Domino® (depending on the browser).

Enabling the editor applet or JavaScript control

You can enable the editor applet in rich text fields only. To enable the editor applet:

  1. Create or select a rich text field.
  2. Choose Design - Field Properties.
  3. On the Field Info tab, in the Web Access section, select "Using Java Applet" or "Using JavaScript Control."

When the editor applet becomes active, it displays as large as the Web browser's window. It is recommended that you resize it. The minimum size recommended is 300 by 500 pixels. To resize it:

  1. In the Objects tab of the Info List in the Programmer's pane, select the rich text field.
  2. Click HTML Body Attributes.
  3. In the Script area, enter the height and width. For example:
    "HEIGHT=300 WIDTH=500"

If the same document is edited by both a Web browser and a Notes® client, there are some additional caveats. For example, it is possible to format a document in the Notes® client using a formatting feature that is not supported in the editor applet. Also, there are features that, once opened and edited in the editor applet, will subsequently not format properly if opened for editing in the Notes® client. These are the formatting features to avoid if editing a document with both the Notes® client and a Web browser:

  • First line indent or outdent
  • Full justification paragraph alignment
  • Tabs
  • Images
  • Ordered lists
  • Tables

In addition, any features that the editor applet cannot interpret are displayed as HTML in green on the document.

Note: Make sure you test your design ahead of time on different browsers. Depending on the user's browser, there may be display problems.

Limitations of rich text fields on the Web

Rich text lite fields are not available on the Web. All rich text must be in a rich text field.

The following items may be lost or corrupted if they are in a rich text field which is edited with a Web browser using Domino® Web Server:

  • embedded images -- may be visible when editing, but will be lost when the document is saved;
  • tab tables - only the visible row will be saved;
  • "hide when" paragraphs which are hidden from the Web -- the entire paragraph will be lost when the document is saved.

Avoid using these items in a rich text field if that field is to be edited with a Web browser.