Html drop-down list how to do it
This article mainly explains "how to do html drop-down list", interested friends may wish to have a look. The method introduced in this paper is simple, fast and practical. Let's let Xiaobian take you to learn "how to do html drop-down list"!
In html, you can create drop-down lists with "" and "" tags, select is used to build drop-down list frames, option is used to define list items; syntax "list option values... "。
Operating environment of this tutorial: Windows 7 system, HTML5 version, Dell G3 computer.
Drop-down lists are the most space-efficient way to select on a web page. By default, only one option is displayed. You can only see all options after clicking the drop-down button. For example, Taobao home page selection area column, used is the drop-down list, we have a look:
We all know that unordered lists are used in conjunction, and ordered lists are used in conjunction. HTML drop-down lists are similar to them and are used in conjunction with. The specific syntax format is as follows:
The label is used to create a drop-down list, and the label represents each item (entry) in the drop-down list.
Let's look at an example:
Age range: under the age of 18 18-28 year-old 28-38 year-old over 38
The results of the operation are shown in the figure:
At this point, I believe everyone has a deeper understanding of "how html drop-down list is done," so let's actually operate it! Here is the website, more related content can enter the relevant channels for inquiry, pay attention to us, continue to learn!