From HTML5 Builder
Jump to: navigation, search

The purpose of containers is to hold and render the components inside them, and also to provide events for you to handle.


Top-level containers are those containers that are not meant to be placed inside another container. Hence, instead of an owner, they are passed the $application global variable when instantiated. For example:

global $application;
$page = new Page($application);

Tip: You will usually subclass them to include event handlers in their definition.

These are some of the top-level containers available on the RPCL:

A webpage.
A screen in a mobile application.
A container for invisible components used to store common reusable code, to later include it in several webpages.