
This directive is used to specify the script language. ABAP and JavaScript are currently supported.
<%@ page language=("ABAP" | "JAVASCRIPT") %>
otrTrim
<%@ page language=("ABAP" | "JAVASCRIPT") otrTrim=("TRUE" | "FALSE") %>
Attribute otrTrim is a boolean value, that is, it can have the values TRUE and FALSE. The default value is FALSE. If it is set to TRUE, all OTR texts on a page are condensed by removing all blank characters from the start and end of a string.
An example of switched on attribute (otrTrim=true):
<%@page language="abap" otrTrim="true" %>
<%
DATA: s TYPE STRING VALUE 'test'.
%>
[<otr> test line </otr>]<br>
[<otr> before <%= s%> middle <%= s%> end. </otr>]<br>
[<%= otr(sbsp_test/it00_otr_1) %>]
The output generated using this coding then looks as follows:
[test line]
[before test middle test end.]
[This is a test for an alias text]
Example of the case when otrTrim is switched off ( otrTrim=false):
<%@page language="abap" otrTrim="false" %>
<%
DATA: s TYPE STRING VALUE 'test'. %>
[<otr> test line </otr>]<br>
[<otr> before <%= s%> middle <%= s%> end. </otr>]<br>
[<%= otr(sbsp_test/it00_otr_1) %>]
The output generated using this coding then looks as follows:
[test line]
[ before test middle test end. ]
[This is a test for an alias text]