The WebLogic Mobility Server JSP Tag Library
The multi-mode JSP tag library (taglib) was introduced for the mobilization of JSP documents.
The functionality of the mmXHTML tags is replicated within a JSP tag library structure. The
taglib, however, provides a particular benefit over mmXHTML by adding some further
optimizations in the performance of WebLogic Mobility Server when delivering JSP content to
the PC channel.
This section covers the following aspects of the WebLogic Mobility Server JSP taglib:
•
Enhanced Performance
•
Syntax
•
Mixing mm-tags and mm:tags
•
Exception Handling and Diagnostics
Enhanced Performance
Marking up content with the JSP mobility taglib results in speed benefits when content is
delivered to PCs. The WebLogic Mobility Server JSP tags reduce the amount of run-time
processing that WebLogic Mobility Server is required to do. The tags run within the servlet
environment, unneeded tags are stripped off, and the streamlined file is sent on to WebLogic
Mobility Server where a minimum of processing is required before it is sent out to the browser.
The result is a faster overall content delivery time.
Syntax
The WebLogic Mobility Server JSP tags mimic their mmXHTML counterparts with the
exception that the tag name is prefixed by "mm:" instead of "mm-".
In order for the tags to be processed, two things are needed at the outset:
•
A taglib declaration at the beginning of the document.
•
An
element surrounding the rest of the file's contents.
<mm:page>
<%@ taglib uri="mmJSPtaglib" prefix="mm"%>
<mm:page>
<html>
<head> Using JSP taglib</head>
<body>
<p>JSP page content here.</p>
</body>
</html>
</mm:page>
mmXHTML headers and tags and the JSP tag library equivalents
mmXHTML
Document must start with XML declaration
and DOCTYPE:
<?xml version="1.0"?>
<!DOCTYPE html PUBLIC "-
//MOBILEAWARE//DTD MMXHTML
1.2//EN"
Part III Fundamentals of Mobile Content
JSP Tag Library
Document must start with taglib declaration and
the page must be wrapped in an <mm:page> tag:
<%@ taglib uri="mmJSPtaglib" prefix="mm"%>
<mm:page>
...
BEA WebLogic Mobility Server User Guide - 21
Need help?
Do you have a question about the WebLogic and is the answer not in the manual?