29.01.2013 Views

WebSphere Application Server - IBM Redbooks

WebSphere Application Server - IBM Redbooks

WebSphere Application Server - IBM Redbooks

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Information request<br />

Currency conversion<br />

The Web container recognizes a user with the identifier attached to its requests.<br />

This identifier is stored in the user’s browser and is the only piece of data stored<br />

in the client-side.<br />

The Java Servlet API supports two ways to associate multiple requests with a<br />

session: cookies and URL rewriting. In either case, the implementation details in<br />

the servlet are the same. The unique session ID is used to track multiple<br />

requests from the same client to the server, and this is what is passed as the<br />

URL or cookie parameter. The actual session object that we are tracking is<br />

maintained on the server.<br />

Customers can request additional information by sending an e-mail to the<br />

company.<br />

Figure C-6 Web site diagram view of information request component<br />

The table below lists the main files involved in this portion of the application.<br />

Table C-9 Information request items<br />

Item Folder/Package Description<br />

inforequest.html info_request This page allows users to request<br />

information pertaining to a product or<br />

products using a HTML form. The user<br />

submits the information to mailer.jsp for<br />

validation and processing. This page is<br />

accessed from index.html.<br />

mailer.jsp info_request This page receives the data passed<br />

from inforequest.html and e-mails it if it<br />

passes the validation.<br />

Note: For additional information about this component please see “Using a<br />

tag library in the Online Catalog sample” on page 301.<br />

The currency exchange option uses a Web service to convert amounts from one<br />

country’s currency to another’s.<br />

Appendix C. Online Catalog application 625

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!