11.3.16 Region Templates
Region templates control the appearance and placement of region attributes.
You place region attributes using substitution strings such as
#BODY#
. Template substitution strings must be in upper case and
begin and end with a pound sign (#).
Parent topic: Creating Custom Themes
11.3.16.1 Region Template Attributes
See Also:
Understanding Template Options and Managing Theme Subscriptions
This section describes some attributes on the Edit Region Template page. To learn more about a specific attribute, see field-level Help.
- Name
- Definition
- Layout
- Sub Regions
- Image
- JavaScript
- Cascading Style Sheet
- JavaScript
- Substitution Strings
Parent topic: Region Templates
11.3.16.1.1 Name
Theme indicates the theme to which the template is a member. Name identifies the name of the template.
Template Class identifies a specific use for the template. When you switch to a new theme, all templates in one theme are mapped to corresponding templates in another theme. App Builder accomplishes this template mapping through the assignment of a template class. Use the Translatable checkbox to indicate that the template contains text strings that require translation.
Parent topic: Region Template Attributes
11.3.16.1.2 Definition
Region templates provide the appearance for a region on a page. Region templates
consist of HTML code to wrap the region content and substitution strings to inject
the region content. #BODY#
is the only required substitution string
and identifies where the source of the region should be placed. All other
substitution strings are optional. Substitution strings can be either:
-
Reserved APEX substitution strings
-
Region positions
Region templates provide the appearance for a portion of a page called a region. Use substitution strings to indicate the existence and placement of a component within the region. #BODY#
is the only required substitution string and identifies where the source of the region should be placed. All other substitution strings are optional. The following are valid substitution strings:
The following reserved APEX substitution strings are used to substitute content from the region defined in Page Designer:
-
#TITLE#
-
#PAGE_TITLE#
-
#SUB_REGION_HEADERS#
-
#FORM_OPEN#
-
#FORM_CLOSE#
-
#REGION_ID#
-
#REGION_STATIC_ID#
-
#REGION_CSS_CLASSES#
-
#REGION_ATTRIBUTES#
-
#REGION_HEADER#
-
#REGION_FOOTER#
-
#REGION_IMAGE#
-
#REGION_IMAGE_URL#
-
#REGION_IMAGE_ALT_TEXT#
-
#REGION_IMAGE_ATTRIBUTES#
The region positions are used to substitute other components inside the region. They
are defined in the Positions section of the region template. This is where you will
find region positions such as #BODY#
,
#SUB_REGIONS#
and other custom positions.
See Also:
Parent topic: Region Template Attributes
11.3.16.1.3 Layout
Page items can be displayed within regions. If the page template layout uses HTML table, each item in a region is part of an HTML table. You can set the attributes of this table using this attribute. Note that this section is not used if the page template layout uses a fixed grid system.
Parent topic: Region Template Attributes
11.3.16.1.4 Sub Regions
Header Template
Sub region header templates together with sub region header entry templates provide the possibility to generate a list of region titles of all the sub regions of the current region.
#ENTRIES#
is the only required substitution string. It identifies
where the sub region header entries should be placed. All other substitution strings
are optional.
The following are valid substitution strings: #ENTRIES#
,
#REGION_ID#
, and #REGION_STATIC_ID#
.Use
#SUB_REGION_HEADERS#
in the region template to place the output
of this template.
Header Entry Template
Sub region header entry templates together with the sub region header templates provide the possibility to generate a list of region titles of all the sub regions of the current region.
The following are valid substitution strings: #SUB_REGION_ID#
,
#SUB_REGION_TITLE#
, #REGION_ID#
, and
#REGION_STATIC_ID#
. Use #ENTRIES#
in the sub
region header template to place the output of this template.
Template
Sub Region templates provide the possibility to wrap the sub regions with additional
HTML code. #SUB_REGION#
is the only required substitution string.
It identifies where the source of the sub region should be placed. All other
substitution strings are optional.
The following are valid substitution strings: #SUB_REGION#
,
#SUB_REGION_ID#
, #SUB_REGION_TITLE#
,
#REGION_ID#
, and #REGION_STATIC_ID#
. Use
#SUB_REGIONS#
in the region template to place the output of
this template.
Parent topic: Region Template Attributes
11.3.16.1.5 Image
Template
The Image template provides the possibility of defining a region image with additional HTML code.
#REGION_IMAGE_URL#
is the only required substitution string and
should be used within an img HTML tag. It specifies the img src attribute. All other
substitution strings are optional.
The following are valid substitution strings:
-
#REGION_IMAGE_URL#
-
#REGION_IMAGE_ALT_TEXT#
-
#REGION_IMAGE_ATTRIBUTES#
-
#REGION_ID#
-
#REGION_STATIC_ID#
Use #REGION_IMAGE#
in the region template to place the output of
this template.
Parent topic: Region Template Attributes
11.3.16.1.6 JavaScript
Tip:
For a list of supported substitution strings and to view examples, see field-level Help.Available attributes include:
-
File URLs - Enter JavaScript file URLs for code to be loaded on this page. Each URL has to be written into a new line. If you provide a minified version of your file you can use the substitution string
#MIN#
to include.min
or#MIN_DIRECTORY#
to include minified/ in your file URL for a regular page view and an empty string if the page is viewed in debug mode. You also have access to the substitution string#APP_VERSION#
if you want to include the application's version in the file URL.JavaScript file URLs you enter here replaces the
#TEMPLATE_JAVASCRIPT#
substitution string in the page template.Do not include opening or closing script tags, just write the URL.
-
Execute when Page Loads - Enter JavaScript code to execute when the page loads. The code is executed after the JavaScript code generated by Oracle APEX.
Do not include opening or closing script tags, just include the JavaScript code.
Parent topic: Region Template Attributes
11.3.16.1.7 Cascading Style Sheet
File URLs
Enter Cascading Style Sheet file URLs to be loaded for this page
template. Each URL has to be written into a new line. If you provide a minified
version of your file you can use the substitution string #MIN#
to
include .min
or #MIN_DIRECTORY#
to include
minified/
in your file URL for a regular page view and an empty
string if the page is viewed in debug mode. You also have access to the substitution
string #APP_VERSION#
if you want to include the application's
version in the file URL.
You do not need to include opening or closing link
tags. Just
include the file URL.
Parent topic: Region Template Attributes
11.3.16.1.8 JavaScript
Tip:
For a list of supported substitution strings and to view examples, see field-level Help.Available attributes include:
-
File URLs - Enter JavaScript file URLs for code to be loaded on this page. Each URL has to be written into a new line. If you provide a minified version of your file you can use the substitution string
#MIN#
to include.min
or#MIN_DIRECTORY#
to include minified/ in your file URL for a regular page view and an empty string if the page is viewed in debug mode. You also have access to the substitution string#APP_VERSION#
if you want to include the application's version in the file URL.JavaScript file URLs you enter here replaces the
#TEMPLATE_JAVASCRIPT#
substitution string in the page template.Do not include opening or closing script tags, just write the URL.
-
Execute when Page Loads - Enter JavaScript code to execute when the page loads. The code is executed after the JavaScript code generated by Oracle APEX.
Do not include opening or closing script tags, just include the JavaScript code.
Parent topic: Region Template Attributes
11.3.16.1.9 Substitution Strings
Substitution strings are used within templates to reference component values. To view the most current list supported substitution strings for a given template, view the template and find the Substitution Strings report.
Tip:
All template substitution strings must be in uppercase letters and begin and end with a number sign (#).Parent topic: Region Template Attributes