O'Reilly logo

Beginning Oracle® Application Express by Paul Turley, Chris Leiter, Dan Wood

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

7.3. Templates

Every time you have created a page, a region, a report, or many other entities in APEX, you have accepted the default choice for a very powerful feature, the template. An APEX template is used to provide the look, feel and, in some cases, the functionality of a type of APEX entity.

Templates provide a framework for the target type of entity, a framework that is combined with the items and attributes specified for the entity to produce the result shown to the user. APEX comes with templates for:

  • Pages

  • Regions

  • Reports

  • Calendars

  • Lists

  • Popup List of Values

  • Labels

  • Buttons

  • Breadcrumbs

Templates act as a kind of container for different types of objects. For instance, a page template can include HTML code for the header and footer of a page, as well as HTML that goes before and after any attribute-specified feature of the page. You could even include JavaScript routines in a page template to add functionality to your application pages.

Templates can take advantage of Cascading Style Sheets (CSS), which are used to define the look and feel of HTML pages. The complete understanding and modification of templates is a fairly complex topic, one that is beyond the limited scope of this book. But you can explore the way that templates affect pages, in particular, as well as see the way that templates work with other APEX attributes in the creation of those pages.

Try It Out: Changing a Page Template

The quickest way to see templates at work is to change different templates for a region ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required