【问题标题】:How to create and arrange my html form?如何创建和排列我的 html 表单?
【发布时间】:2015-08-18 17:53:06
【问题描述】:

我想在 html 中创建一个像这张图片一样的表单。但我不能像这张照片那样安排它。

到目前为止,这是我的代码。

 <form>
 <div>
 <br></br>
 <p><font size="2">Prepared and Submitted by: _________________           Reviewed & Validated by: __________________  Noted: ___________________  
</p>
<p> &nbsp;&nbsp;&nbsp;&nbsp;SCHOOL HEAD &nbsp;&nbsp;&nbsp;&nbsp; DIVISION    REPRESENTATIVE  SCHOOLS DIVISION SUPERINTENDENT </pr>
</font>

<p><strong><font size="3">Guidelines:</strong> </font> </pr>

 <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font size="1">1. After receiving and validating the Report for Promotion submitted by the class adviser, the School Head shall compute the grade level total and school total.</font></pr>
 <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font size="1">2. This report together with the copy of Report for Promotion submitted by the class adviser shall be forwarded to the Division Office by the end of the school year.</font>  </pr>
 <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font size="1">3. The Report on Promotion per grade level is reflected in the End of School Year Report of GESP/GSSP.</font></pr>
 <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font size="1">4. Protocols of validation & submission is under the discretion of the Schools Division Superintendent.</font></pr>

</div>
</form>

我是 html 新手。请帮帮我....

【问题讨论】:

    标签: html forms html-table


    【解决方案1】:

    作为html的新用户,你应该看看css属性。

    它将帮助您进行元素定位。

    例如,使用边距和填充属性:

    http://www.w3schools.com/css/tryit.asp?filename=trycss_margin_sides

    还可以尝试使用 div 锚点拆分您的视图。 您可以将 4 个点放在一个 div 中,然后使用 css 属性将 div 放在右侧。

    【讨论】:

      【解决方案2】:

      如果你愿意,你可以使用 Bootstrap。你可以在这里得到它:getbootstrap.com

      以下可能会起作用:

      <form class="form-horizontal">
      <fieldset>
      
      <!-- Form Name -->
      <legend>Form Name</legend>
      
      <!-- Text input-->
      <div class="col-md-4">
      <div class="control-group">
        <label class="control-label" for="textinput">Prepared and Submitted by:</label>
        <div class="controls">
          <input id="textinput" name="textinput" type="text" placeholder="placeholder" class="input-xlarge">
          <p class="help-block">SCHOOL HEAD</p>
        </div>
      </div>
      </div>
      
      <!-- Text input-->
      <div class="col-md-4">
      <div class="control-group">
        <label class="control-label" for="textinput">Reviewed &amp; Validated by:</label>
        <div class="controls">
          <input id="textinput" name="textinput" type="text" placeholder="placeholder" class="input-xlarge">
          <p class="help-block">DIVISION    REPRESENTATIVE</p>
        </div>
      </div>
      </div>
      
      <!-- Text input-->
      <div class="col-md-4">
      <div class="control-group">
        <label class="control-label" for="textinput">Noted: </label>
        <div class="controls">
          <input id="textinput" name="textinput" type="text" placeholder="placeholder" class="input-xlarge">
          </div>
        </div>
      </div>
      <div class="col-md-12">
      <div class="control-group">
        <label class="control-label" for="textinput">Guidelines: </label>
        <ol class="list-unstyled"> 
             <li>After receiving and validating the Report for Promotion submitted by the class adviser, the School Head shall compute the grade level total and school total.</li>
             <li>This report together with the copy of Report for Promotion submitted by the class adviser shall be forwarded to the Division Office by the end of the school year.</li>
             <li>The Report on Promotion per grade level is reflected in the End of School Year Report of GESP/GSSP.</li>
             <li>Protocols of validation & submission is under the discretion of the Schools Division Superintendent.</li>
        </ol>
      </div>
      </div>
      </fieldset>
      </form>
      

      【讨论】:

      • 也许你应该更加强调它使用 Bootstrap 的事实,至于不知道这一点的人可能并不完全清楚。
      • 是的。这是真的@Peter :)
      猜你喜欢
      • 2015-02-27
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2020-07-24
      • 1970-01-01
      • 2011-01-21
      • 2018-02-03
      相关资源
      最近更新 更多