zoukankan      html  css  js  c++  java
  • 单选/多选框

    <!DOCTYPE>
    <!DOCTYPE html>
    <html>
    <head>
     <title>from表单</title>
     <meta charset="utf-8">
    </head>
    <body>
    <form method="get" action="">
     <p>最喜欢的水果:</p>
     1.苹果<input type="radio" name="f" value="苹果" checked="checked">
     2.橘子<input type="radio" name="f" value="橘子">
     3.芒果<input type="radio" name="f" value="芒果"><br>
     <br>
     <br>
     <br>
     <p>我喜欢的水果有</p>
     1.苹果<input type="checkbox" name="d" value="苹果">
     2.橘子<input type="checkbox" name="d" value="橘子">
     3.芒果<input type="checkbox" name="d" value="芒果"><br>
     
    <br>
    <br>
    <br>
    <form action="" method="get" class="form-example">
      <div class="form-example">
        <label for="name">Enter your name: </label>
        <input type="text" name="name" id="name" required>
      </div>
      <div class="form-example">
        <label for="email">Enter your email: </label>
        <input type="email" name="email" id="email" required>
      </div>
      <div class="form-example">
        <input type="submit" value="Subscribe!">
      </div>
    </form>
    </form>
    </body>
    </html>
  • 相关阅读:
    js精度丢失问题处理
    button居中
    js存储 cookie,localStorage,sessionStorage的比较
    js 常用的DOM,BOM操作
    js事件代理理解
    oneplus前端开发面试
    instanceof
    js原型和原型链
    js构造函数
    NC 6.X笔记(编辑中)
  • 原文地址:https://www.cnblogs.com/l-mz/p/9657817.html
Copyright © 2011-2022 走看看