djButton - Dojo Button

Activates an event handler.

Category

Dojo Form

Syntax

<xe:djButton attributes>content</xe:djButton>
Table 1. Essential properties
Property Description
id Defaults to djButton1, djButton2, and so on.
label Specifies the text that appears on the button.
onClick Specifies an action to be taken when the button is clicked.

Usage

This is a Dojo control.

At run time, the user clicks the button to activate its onClick event handler.

This control is not tested against the latest accessibility standards. The recommended accessible path is the Button control.

Examples

This example consists of a Button that activates a client event.
<xp:table>
	<xp:tr>
		<xp:td>Button</xp:td>
		<xp:td>
			<xe:djButton id="djButton1" label="say hello"
				defaultValue="blue">
				<xp:eventHandler event="onClick" submit="false">
					<xe:this.script><![CDATA[alert("Hello, world!")]]></xe:this.script>
				</xp:eventHandler>
			</xe:djButton>
		</xp:td>
	</xp:tr>
</xp:table>