Page Variables |
Top Previous Next |
Pages also have internal variables and functions. All of them start with "page." Note it is case sensitive! page.setCurrentPage(newpage): call this function to change pages. Pass in a string containing a comma delimited list of the pages you wish to display. For example, to change to page2: page.setCurrentPage("page2")
Normally the string will just contain a single page name, but you can specify multiple pages and create overlaid pages. Overlaid pages allow you to create a single page with common content (such as a menu, or overview) and overlay other pages on this common content. To overlay two pages, just set this variable to a comma delimited list of the two pages: page.setCurrentPage("page1, page2")
When you have overlaid pages and switch to edit mode, there are a couple important points: You can drag any existing control and it will remain on its original page, however, if you add a new control, either by dragging it onto the page, or duplicating an existing control (no matter what page it was originally on), the new control will always be on the first page listed (i.e. page1 in the example above). Because of this, if you are creating a page with common content, we recommend listing it last so that you can create and edit the other pages while viewing the common content.
|