HTML5 adds new properties to the input box, such as placehoLder (Placeholder), which indicates that some text is pre-placed in the text box. Placeholders are sample content that the text box can accept, and the general color is gray. As soon as one stone hits the text box, he disappears. If you delete all the entries you have entered, and then stand outside the text box, it will appear again. Try JavaScript, of course, to achieve this. But HTML5 solves the problem with only one placeholder attribute.
<!DOCTYPE HTML><HTMLLang= "en"><Head><MetaCharSet= "UTF-8"><title>Document</title><style>Body{padding:100px;}input{Display:Block;width:300px;Height:30px;Line-height:30px;Outline:None;text-indent:10px;Margin-bottom:10px;}</style></Head><Body> <inputtype= "text"placeholder= "Here is the hint text, placeholder, you can enter" white bug "> <input type= "text" placeholder= "Here is the hint text, placeholder" > </Body></HTML>
As shown in the following:
HTML5 input placeholder placeholder entry box hint text