您好,登錄后才能下訂單哦!
==============================================
1.required --- 必填字段驗證
2.minlength, maxlength --- 字符長度驗證
3.min, max --- 數值范圍驗證 用于number,range 和日期時間類型
4.step --- 步長驗證
5.pattern --- 正則表達式驗證
6.novalidate(form中) ---禁用表單驗證
formnovalidate(submit中) ---禁用表單驗證
<form action=" " method="post">
<div>用戶名:<input type="text" minlength="3" maxlength="10" required></div>
<div>密碼:<input type="password" minlength="6" maxlength="8" required></div>
<div>郵箱:<input type="email" pattern=" ^[\w-]+(\.[\w-]+)*@[\w-]+(\.[\w-]+)+$" required></div>
<div>日期:<input type="date" min="2016-02-05" max="2017-02-05" required> </div>
<div>訂購數量:<input type="number" min="10" max="50" step="5" required> </div>
<div>音量:
<form oninput="out.value=in.value">
<input type="range" name="in" value="0">
<output name="out">0</output>
</form>
</div>
<input type="submit">
</form>
免責聲明:本站發布的內容(圖片、視頻和文字)以原創、轉載和分享為主,文章觀點不代表本網站立場,如果涉及侵權請聯系站長郵箱:is@yisu.com進行舉報,并提供相關證據,一經查實,將立刻刪除涉嫌侵權內容。