HTML: <command>
XHTML: <command/>  or  <command />

HTML5 only. Used within a menu element, a command is an interactive element that represents an immediate action that can be triggered by the user (usually via onclick).

Start/End Tags

This is an empty element. It must be closed with a trailing slash in the XML serialization of HTML5.


  • HTML5


Values: None in HTML. checked="checked" in XHTML5.
Indicates that a command is selected.


Values: None in HTML. disabled="disabled" in XHTML5.
Indicates that a command is not available in the current state.


Values: URL
Specifies the location of an image to be used as a button for the command.


Values: text (may not be an empty string)
Required. Provides the name of the command, as displayed to the user.


Values: text
Specifies the name of a group of commands when the command type is set to radio.


Values: text
Provides a hint describing the command to aid the user.


Values: command | checkbox | radio
Indicates the kind of command. The command keyword indicates a normal command with an associated action. checkbox indicates the command state can be toggled on or off. radio indicates the command represents the selection of one item from a list of items.
  <command onclick="cut()" label="Cut">
  <command onclick="copy()" label="Copy">
  <command onclick="paste()" label="Paste">
  <command onclick="delete()" label="Clear">

Rendered Example


HTML5 menus are not yet supported and can not be displayed.