W
W
wadowad2022-02-24 16:02:06
HTML
wadowad, 2022-02-24 16:02:06

How to "correctly" lay out a menu with a table of contents?

How correctly from the point of view of semantics to make up a menu with a title?

For example, there is such a simple thing: "Sort: by price, by rating, by novelty".

How true is the following?

<dl>
  <dt>Сортировка</dt>
  <dd>
    <ul>
      <li><a href="#">по цене</a></li>
      <li><a href="#">по рейтингу</a></li>
      <li><a href="#">по новизне</a></li>
    </ul>
  </dd>
</dl>

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexander Vasiliev, 2022-02-24
@amvasiljev

Good afternoon.
The above example can hardly be called a "menu with a table of contents".
The given code from the point of view of https://validator.w3.org/ without errors.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question