"Quickening the Pace of JSP Development" Tuesday, March 09, 2010
Home Products Pricing Company Contact Us Samples Download Forums Javadoc Customers
    « Form Tags »
    « I/O Tags »
    « Format Tags »
    « Utility Tags »
Dialog Box Tag Example

Use the <dotj:dialogbox> tag as a way to display important information on your site. It can also be used for your typical data entry forms.

In this first example, the dialog box has rounded edges, which gives it a nice touch. Also, you can display a titlebar, which in this example can be collapsed or expanded. Another nice feature is the ability to move the dialog, which is supported for Internet Explorer 4.x and Netscape 6.x and above.

Rounded Dialog Box that Expands and Collapses
With a dotJ dialog box, you can provide rounded edges that give the dialog that extra touch.

Another feature is the ability to expand and collapse the dialog. This is great for screens where real estate is a premium.



In this example, we simply display a typical dialog box (nothing too fancy). Each dialog box on the page can have its own look and feel by specifying a styleprefix attribute.

 My Own Look and Feel

  • The styleprefix attribute can be used to provide a customized look and feel for each dialog box.

  • Simply create the appropriate CSS styles and you're in business!

Servlet developers can also create their own dialog boxes. Just be sure to call the DialogBox.setRequest method and capture the resulting HTML by calling DialogBox.print. Another feature used in the example below is the use of the initialstate attribute. Here, we initially display the dialog box as collapsed.

Using Java Code
This is also the text for the dialog box displayed using code.



          Back to Samples page


home : products : pricing : company : contact us : samples : download : forums : customers

Copyright © 2000-2004 dotJ Software Inc. All rights reserved.