XUL:wizardpage
From MDC
« XUL Reference home [ Examples | Attributes | Properties | Methods | Related ]
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
[edit] Examples
<?xml version="1.0"?>
<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
<wizard id="theWizard" title="Secret Code Wizard"
xmlns="http://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>
[edit] Attributes
|
Inherited from XUL element |
- 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.
- 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 a next 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
trueto allow the next page to be displayed andfalseto 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
trueto accept the page change andfalseto prevent the page from changing. This code is called before the wizard's onwizardnext 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
trueto allow the previous page to be displayed andfalseto disallow moving to the previous page.
- onpageshow
- Type: script code
- The code in this attribute is called when the page is shown.
- 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 the next attribute. The wizard always starts with the wizardpage that appears first in the wizard child list.
[edit] 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 a
nextattribute, 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 the next attribute. The wizard always starts with the wizardpage that appears first in the wizard child list.
|
Inherited from XUL element Inherited from DOM element |
[edit] Methods
|
Inherited from XUL element Inherited from DOM element |