Name

<ora:forward>

Synopsis

The <ora:forward> action forwards the request to another web resource, exactly the same way as the standard <jsp:forward> action except that it accepts an EL expression as the page attribute and supports nested <ora:param> actions instead of <jsp:param> actions. It’s useful as a gap filler until the next JSP specification version is released; the standard forward action is then expected to support EL expressions.

Syntax 1: Without parameters

<ora:forward page="pageOrContextRelativePath" />

Syntax 2: With nested <ora:param> actions

<ora:forward page="pageOrContextRelativePath" />
  One or more <ora:param> actions
</ora:forward>

Attributes

Attributename

Java type

Dynamic valueaccepted

Description

page
String

EL expression

The forward target resource, as a page- or context-relative path

Example

<%-- 
  Forward to a page in the same directory
--%>
<ora:forward page="aPage.jsp" />
  
<%-- 
  Forward to a page in the application's /error directory
--%>
<ora:forward page="/error/aPage.jsp" />

Get JavaServer Pages, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.