deleted Obsolete
This feature is obsolete. Although it may still work in some browsers, its use is discouraged since it could be removed at any time. Try to avoid using it.
Note: The command
element has been removed from Gecko 24.0 in favor of the <menuitem>
element. Firefox has never supported this command
element, and the existing implementation of the HTMLCommandElement
DOM interface has been dropped from Firefox 24.
The command
element represents a command which the user can invoke.
Content categories | Flow content, phrasing content, metadata content. |
---|---|
Permitted content | None, it is an empty element. |
Tag omission | The start tag is mandatory, but, as it is a void element, the use an end tag is forbidden. |
Permitted parent elements |
<colgroup> only, though it can be implicitly defined as its start tag is not mandatory. The <colgroup> must not have a <span> as child. |
DOM interface |
HTMLCommandElement Obsolete since Gecko 24
|
This element includes the global attributes.
checked
type
attribute is checkbox
or radio
.disabled
icon
label
radiogroup
type
of radio
, that will be toggled when the command itself is toggled. This attribute must be omitted unless the type
attribute is radio
.type
command
or empty which is the default state and indicates that this is a normal command.
checkbox
indicates that the command can be toggled using a checkbox.
radio
indicates that the command can be toggled using a radiobutton.
<command type="command" label="Save" icon="icons/save.png" onclick="save()">
Specification | Status | Comment |
---|---|---|
WHATWG HTML Living Standard The definition of '<command>' in that specification. | Living Standard | |
HTML5 The definition of '<command>' in that specification. | Recommendation |
Feature | Chrome | Firefox (Gecko) | Internet Explorer | Opera | Safari |
---|---|---|---|---|---|
Basic support | No support | No support | No support | No support | No support |
Feature | Android | Firefox Mobile (Gecko) | IE Mobile | Opera Mobile | Safari Mobile |
---|---|---|---|---|---|
Basic support | No support | No support | No support | No support | No support |
© 2005–2017 Mozilla Developer Network and individual contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/command