Name

<ora:fileWrite>

Synopsis

The <ora:fileWrite> action writes its body content to the console, the application log, or a specific file.

Syntax

<ora:fileWrite [fileName="fileName"] />

Attributes

Attributename

Java type

Dynamic valueaccepted

Description

fileName
String

No

Either an absolute file path or log to write to the application log file. If omitted, writes to System.out.

Example

<%-- 
  Write and error message to the application log file.
--%>
<ora:fileWrite filename="log">
  Error message: <c:out value="${pageContext.exception.message}" />
</ora:fileWrite>

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.