I would like to use the improved html5 semantics. I am creating a search area, and the search area should have a background and contain things related to the search, such as autocomplete and search hints.
Is there any consensus on what type of element should look like a search area?
- Should it be NAV because search is a navigation method?
- Should there be a SECTION because this is the secret section of the page?
- Should it be a DIV, because there is no clear semantics in the wrapper of elements related to the search?
The markup looks something like this:
<?whatElement?>
<input type="search" placeholder="Search for a name or ID..." required />
<a href="#" class="search button">Search</a>
</?whatElement?>
Thanks for your thoughts.
source
share