The iFrame Solution
An iFrame element defines an inline frame for the inclusion of external objects, including other HTML documents. It enables you to easily open and position a Web page anywhere inside your main page without the hassle of classical frames. The following is HTML code for an iFrame:
<IFRAME SRC="xxx.htm" width="100" height="200">
<!-- Alternate content for non-supporting browsers -->
In the registration page of the example application, you will embed an iFrame containing another JSP page, which the application will use to communicate with the Servlet on behalf of its parent page. As a result, the application transparently submits the iFrame page without the user ever knowing it, thus eliminating the hang that occurs when it submits a page to the server. Figure 1 shows how the registration page looks.