Home >Web Front-end >HTML Tutorial >HTML learning summary 8_html/css_WEB-ITnose

HTML learning summary 8_html/css_WEB-ITnose

WBOY
WBOYOriginal
2016-06-24 11:46:521250browse

1. Create a list

For situations involving many options, you can consider a list, which also becomes a menu. Lists can contain as many options as they want while taking up very little space on the form.

To create a list, start with a double-sided

 

 

 

By default, the form result will return the selected text. If you want to return different content, you can include the value attribute in the opening option tag.

To display the list in the format shown above, you can enclose a group of options with the tag. For each option group, you can use the label attribute. Defines the text of the header file. Here is the code for the list shown above:

🎜> 1405

  lt;option>SuperLaser Value Edition< ;/option>

    

  

   

2. Input types added in HTML5

HTML5 provides some input types that can make the form more beautiful. If the user's browser does not support these types, they will be displayed as text areas, so you can freely use these types without worrying about upward compatibility issues. < ;input type="number" name="copies" min="0" max="100" step="1" value="1">

min and max control the minimum and maximum values ​​respectively , the step attribute specifies that when the user clicks the up or down arrow button, the value increases or decreases each time. The value attribute defines the default value.

A slider is a sliding bar that you can slide to move from one side to the other. Its type is range, and its properties are almost the same as the rotation box.

 

 

For standard dates, use type="date". This allows the user to select a specified date from the calendar. You can also use any of the following types to select other dates or time-related choices

 

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn