The following sections describe how to configure JavaServer Faces (JSF) and JSP Tag Standard Library (JSTL) with WebLogic Server.
JSF 2.0 (JavaServer™ Faces) and JSTL 1.2 (JSP™ Standard Tag Library) packages are bundled with WebLogic Server as shared Web application libraries. These libraries can be referenced by standard Web applications that use JSF or JSTL functionality.
For information on referencing these shared libraries with your Web applications, see "Creating Shared Java EE Libraries and Optional Packages" in Developing Applications for Oracle WebLogic Server.
JavaServer Faces technology simplifies building user interfaces for JavaServer applications. Developers of various skill levels can quickly build Web applications by: assembling reusable UI components in a page; connecting these components to an application data source; and wiring client-generated events to server-side event handlers.
For more information about JSF technology, see JavaServer Faces (JSF) product overview from Sun Microsystems at http://www.java.sun.com/javaee/javaserverfaces
.
The JavaServer Pages Standard Tag Library (JSTL) encapsulates as simple tags the core functionality common to many Web applications. JSTL has support for common, structural tasks such as iteration and conditionals, tags for manipulating XML documents, internationalization tags, and SQL tags. It also provides a framework for integrating existing custom tags with JSTL tags.
For more information about JSTL technology, see JavaServer Pages Standard Tag Library (JSTL) product overview from Sun Microsystems at http://www.java.sun.com/products/jsp/jstl
.
The following packages are available as shared libraries:
JSF library (Sun's Glassfish Community) – https://javaserverfaces.dev.java.net
JSTL library – http://java.sun.com/products/jsp/jstl/
The libraries are bundled as WAR
files and are located in the WL_HOME/common/deployable-libraries
directory. The JSF libraries include the JSTL JAR
files for convenience, so that if an application references a JSF library, it automatically gets JSTL support as well.
Separate JSF 2.0 and JSTL 1.2 JAR
files and implementation JAR
files are also provided in the WL_HOME/server/lib/api.jar
file. You can reference these JAR
files for compilation purposes or when using other utilities while developing Web applications.
Since JSF and JSTL libraries are provided as Web application libraries, they must be deployed before the Web application that is using JSF or JSTL functionality is deployed. The libraries can be deployed using the Administration Console or with the command-line weblogic.Deployer
tool.
Here's an example of deploying a JSF 2.0 library using the weblogic.Deployer
command-line:
java weblogic.Deployer -adminurl t3://localhost:7001 -user weblogic -password weblogic -deploy -library d:/beahome/wlserver_10.0/common/deployable-libraries/jsf-2.0.war
This command deploys the JSF 2.0 library using the default library-name
, specification-version
and implementation-version
defined by the MANIFEST.MF
in the library.
After a library is deployed, the extension-name
, specification-version
and implementation-version
of the library can be found in Administration console. This information can also be found in the MANIFEST.MF
file of the library WAR
file.
For more information on deploying a Web module, see "Preparing Applications and Modules for Deployment" in Deploying Applications to Oracle WebLogic Server.
To reference a JSF or JSTL library, a standard Web application can define a <library-ref>
descriptor in the application's weblogic.xml
file. Here is an example:
<library-ref> <library-name>jsf</library-name> <specification-version>2.0</specification-version> <implementation-version>2.0</implementation-version> <exact-match>false</exact-match> </library-ref>
For more information on referencing a Web application library, see "Creating Shared Java EE Libraries and Optional Packages" in Developing Applications for Oracle WebLogic Server.
JSF 1.x and JSTL 1.x packages are also bundled with WebLogic Server as shared libraries. Existing Web applications that use JSF 1.x and JSTL 1.x functionality can run on the WebLogic Server. You can choose the appropriate JSF or JSTL library based on your Web application.
For more information on the supported JSF 1.x and JSTL 1.x libraries, see Using JSF and JSTL With Web Applications at http://download.oracle.com/docs/cd/E13222_01/wls/docs92/webapp/configurewebapp.html
in the WebLogic Server 9.2 documentation and http://download-llnw.oracle.com/docs/cd/E11035_01/wls100/webapp/configurejsfandjtsl.html
in the WebLogic Server 10.0 documentation.