HTML and CSS Reference
In-Depth Information
Name
menu
Synopsis
<menu> . . . </menu>
Represents a list of interactive options or commands such as a menu of options in a web ap-
plication. When the
menu
is a pop-up menu, its contents are one or more
menuitem
elements.
In the HTML5 Candidate Recommendation, an option in a
menu
is provided by the
command
element, but the more forward looking HTML5.1 draft and the living WHATWG specifica-
tion have replaced
command
with
menuitem
.
Note
In HTML 4.01, the deprecated
menu
element indicates a menu list, which consists of one or
more list items (
li
). Menus were intended for a list of short choices, such as a menu of links
to other documents.
Usage
Categories:
Flow content; if the
type
element is in the toolbar state, then palpable content.
Permitted contexts:
Where flow content is expected. If the
type=popup
, then as the child of a
menu
element
that is in the pop-up state.
Permitted content:
If
type=toolbar
, flow content or zero or more
li
elements. If
type=popup
, zero or more
menuitem
elements, zero or more
hr
elements, and zero or more
menu
elements with
type=popup
.