English

How To: Use Java ADF Web mapping application with Servlet 2.4 and JSTL 1.1 versions

Summary

Instructions provided describe how to change the Java ADF Web mapping application to work with Servlet 2.4 and JSTL 1.1 versions.

Procedure

The Java ADF Web mapping application, by default, is created with Servlet 2.3 and JSTL 1.0 declarations. To update the declarations to Servlet 2.4 and JSTL 1.1, follow the steps below:

A. Export the Web mapping application created from Manager.
B. Extract the contents of the Web archive (WAR) to a folder.

For Servlet 2.4:
1. Open the file web.xml under the WEB-INF folder.
2. Replace the lines below,

<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
<web-app id="WebApp_ID">



with

<web-app id="WebApp_ID" xmlns="http://java.sun.com/xml/ns/j2ee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
version="2.4">


Now the web.xml file displays:

<?xml version="1.0" encoding="UTF-8"?>

<web-app id="WebApp_ID" xmlns="http://java.sun.com/xml/ns/j2ee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
version="2.4">
....
....
....
</web-app>



For JSTL 1.1:
1. Open the file: mapviewer.jsp.
2. Replace the line below,

<%@taglib uri="http://java.sun.com/jstl/core" prefix="c"%>



with

<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>



3. Replace the JSTL 1.0 JAR files at WEB-INF/lib folder with JSTL 1.1 JAR files.

Note:
The JSTL library is comprised of two JAR files, standard.jar and jstl.jar. It may be necessary to download JSTL 1.1 from the Apache Web site at http://jakarta.apache.org/taglibs/doc/standard-doc/intro.html

Now the Java ADF Web mapping application uses Servlet 2.4 and JSTL 1.1 declarations.