name="orders"
type="penguins.access.db2.Orders"
>
Figure 80. Bean tag in the listordersPage.jsp
The JSP page, listordersPage.jsp, picks up the bean name of orders and
finds the bean instance of penguins.access.db2. Orders from the Request
object., the information contained in the bean, is accessible via the bean's
public methods. See Section 3.7.0.1,  AccessUserstuf action=listorders 
on page 104, where we discuss the Orders bean.
  We then use the beans to print the previous orders in a table. This is
accomplished by iterating through all the orders contained in the bean with
the following code:
for (Enumeration e=orders.orderIDs(); e.hasMoreElements();) {
String key=(String) e.nextElement();
out.println(""+key+"");
out.println(""+orders.timestamp(key)+"");
out.println(""+orders.productID(key)+"");
}
The complete listing of listorderspage.jsp is provided in Appendix D.19,
 Listorderspage.jsp  on page 196
3.7.0.1 AccessUserstuf action=listorders
The following sequence of tasks is performed when the servlet is invoked with
the action parameter containing the value of listorders:
1. The listorders action retrieves the username and password from the
Session object by using the getUsername and getPassword method:
String username=getUsername(session);
String password=getPassword(session);
2. We verify the username and password pair using the passwordsMatch
method previously defined in Section 3.5.3.4,  AccessUserstuf
action=login  on page 89. If successful, we proceed to the next step or
redirect to an error page regarding the username and password
authentication error.
104
Linux Web Hosting with WebSphere, DB2, and Domino




  

Home

About Services Network Support FAQ Order Contact
 

Linux Web Hosting

Our partners:Jsp Web Hosting Unlimited Web Hosting Cheapest Web Hosting  Java Web Hosting Web Templates Best Web Templates PHP Mysql Web Hosting Interland Web Hosting Cheap Web Hosting PHP Web Hosting Tomcat Web Hosting Quality Web Hosting Best Web Hosting  Mac Web Hosting 

Lunarwebhost.net  Business web hosting division of Vision Web Hosting Inc. All rights reserved