This element defines a page in a wizard
. The content in the pages should be placed inside the wizardpage
element.
More information is available in the XUL tutorial.
- Attributes
- description, label, next, onpageadvanced, onpagehide, onpagerewound, onpageshow, pageid
Examples
<?xml version="1.0"?> <?xml-stylesheet href="chrome://global/skin/" type="text/css"?> <wizard id="theWizard" title="Secret Code Wizard" xmlns="https://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"> <script> function checkCode(){ document.getElementById('theWizard').canAdvance = (document.getElementById('secretCode').value == "cabbage"); } </script> <wizardpage onpageshow="checkCode();"> <label value="Enter the secret code:"/> <textbox id="secretCode" onkeyup="checkCode();"/> </wizardpage> <wizardpage> <label value="That is the correct secret code."/> </wizardpage> </wizard>
Attributes
-
description
- Type: string
- Descriptive text to appear in addition to the dialog title.
-
label
- Type: string
-
The label that will appear on the element. If this is left out, no text appears. For an editable
menuitem
element the value of this attribute is copied to themenulist
.value property upon user selection of themenuitem
.
next
- Type: id
- Set to the
pageid
of the nextwizardpage
after this one. When set, the page with this pageID is displayed when the Next button is pressed. This can be used to create wizards that do not have a linear sequence. If one of the pages has anext
attribute, all of the pages should have one, except that last page.
-
onpageadvanced
- Type: script code
- This should be set to code which is called when the user presses the Next button while on the current page. Return
true
to allow the next page to be displayed andfalse
to disallow moving to the next page.
-
onpagehide
- Type: script code
- The code in this attribute is called when the page is hidden, such as when moving to another page. Return
true
to accept the page change andfalse
to prevent the page from changing. This code is called before thewizard
'sonwizardnext
and related functions.
-
onpagerewound
- Type: script code
- This should be set to code which is called when the user presses the Back button while on the current page. Return
true
to allow the previous page to be displayed andfalse
to disallow moving to the previous page.
-
onpageshow
- Type: script code
- The code in this attribute is called when the page is shown.
pageid
- Type: id
- This attribute should be set to a string that identifies the page's identifer in the
wizard
. This is used with thenext
attribute. The wizard always starts with thewizardpage
that appears first in the wizard child list.
Properties
-
next
- Type: string
wizardpage
id - Set to the
pageid
of the next page after this one. When set, the page with this pageID is displayed when the Next button is pressed. This can be used to create wizards that do not have a linear sequence. If one of the pages has anext
attribute, all of the pages should have one, except that last page.
-
pageid
- Type: string
wizardpage
id - This attribute should be set to a string that identifies the page's identifer in the
wizard
. This is used with thenext
attribute. The wizard always starts with thewizardpage
that appears first in the wizard child list.
Inherited Properties |