input required属性

202 阅读1分钟

 如果使用该属性,则字段是必填(或必选)的。

 <input type="text" required="required" placeholder="please input your title" autofocus="autofocus"/>\