Back to Chromium

Search Landmark

third_party/aria-practices/src/content/patterns/landmarks/examples/search.html

153.0.7995.1951 B
Original Source

Search Landmark

Definition

  • A search landmark contains a collection of items and objects that, as a whole, combine to create search functionality to content on the website.
  • ARIA 1.2 Specification: search landmark

Design Patterns

  • Use the search landmark instead of the form landmark when the form is used for search functionality.
  • If a page includes more than one search landmark, each should have a unique label.

Use the HTML search element to define a search landmark.

HTML Example

<search>

<input type="search" aria-label="search text" size="20">

<input type="submit" value="Search">

</search>

A role="search" attribute is used to define a search landmark.

ARIA Example

<form role="search" >

<input type="search" aria-label="search text" size="20">

<input type="submit" value="Search">

</form>