1. Computing & Technology

Discuss in my forum

Your First HTML Form

The HTML for the Form

By , About.com Guide

The following is the HTML for a simple HTML Form web page. It uses a mailto link to send the form data.

<!doctype html>
<html>
  <head>
    <meta charset="utf-8">
    <title>Feedback Form</title>
  </head>
  <body>
    <h1>Feedback Form</h1>
    <form action="mailto:your email address" method="get" enctype="text/plain">
      <p>
        Name: <input type="text" id="name" size="30">
      </p>
      <p>
        Please rate my site from 1 to 10 (1 = bad and 10 = good): <br />
        <select id="rating"><br />
          <option>1</option>
          <option>2</option>
          <option>3</option>
          <option>4</option>
          <option>5</option>
          <option>6</option>
          <option>7</option>
          <option>8</option>
          <option>9</option>
          <option selected>10</option>
        </select>
      </p>
      <p>
        How would you suggest I improve it?<br />
        <textarea id="improve" rows="5" cols="30"></textarea>
      </p>
      <p>
        <input type="submit" value="Send Feedback"> <input type="reset">
      </p>
    </form>
  </body>
</html>

©2012 About.com. All rights reserved.

A part of The New York Times Company.