Đang chuẩn bị liên kết để tải về tài liệu:
WebSphere Studio Application Developer Version 5 Programming Guide part 30

Đang chuẩn bị nút TẢI XUỐNG, xin hãy chờ

WebSphere Studio Application Developer part 30 provides integrated development tools for all e-business development roles, including Web developers, Java developers, business analysts, architects, and enterprise programmers. The customizable, targeted, role-based approach of WebSphere Studio Application Developer will be characteristic of all new products built on the WebSphere Studio Workbench. It is well integrated with WebSphere Application Server and provides built-in server test environments that can be used for testing and profiling Web applications | The jspsql.jar file contains the tags and dbbeans.jar contains the actual classes used to access the database. Creating a JSP We now create a TestTagLib.jsp file to use tag libraries. See Working with JSPs on page 210 for details about creating a new JSP. Open TestTagLib.jsp in Page Designer. You can use the JSP editor to insert the database tags into your page when you are in the Design view. To be able to use the custom tags from the database tag library you first have to do two things Import the tag library into your Web application as described above. Create the taglib directive in the JSP. To insert the taglib directive bring up the context menu on the page in the Design view and select Page Properties. In the dialog shown select JSP Tags and JSP Directive - taglib from the Tag Type drop-down menu Figure 8-16 . Figure 8-16 Insert JSP taglib directive Click Add to select the tag library to add and the dialog shown in Figure 8-17 is displayed. 264 WebSphere Studio Application Developer Version 5 Programming Guide Figure 8-17 Selecting a tag library Click Import to locate the jspsql .jar file to import. The Import a Tag Library dialog opens Figure 8-18 . Click Browse to locate the JAR file wsadhome wstools eclipse plugins com.ibm.etools.dbjars_5.0.1 jars jspsql.jar Figure 8-18 Importing a tag library Chapter 8. Developing Web applications with database access 265 Be sure to select Add an alias URIso that the tag library is added to the web.xml file. The entry can be found on the References page. Click OK to close the dialog. Now the tag library has been imported. Select the jspsqlcheck box to add it to the JSP Figure 8-19 . Figure 8-19 Select the jspsql tag library Select OK twice to close the dialog. The following tag is inserted into your JSP @taglib uri jspsql prefix dab The full TestTagLib.jsp is available in sg246957 sampcode dev-webdb 266 WebSphere Studio Application Developer Version 5 Programming .