Edit Article

Edited by Chris, Teresa

Selectable lists in HTML forms may be easy to use, but the tricky part is creating them. This article will explain how to code these things correctly.

Ad

Edit Steps

  1. 1
    Type the <form> tag into the HTML file.

    Define a Selectable List in HTML Step 1.jpg
    Ad
  2. 2
    Determine what type of information you need to collect from your visitor. Whether it's straight text (useful for names and addresses) or a password (for pages that require setup information), or yes/no checkboxes, or even a drop-down list of reasons (and lots of other types too), you'll never run out of items or reasons toput stuff on the page. Set the different types below for additional information to add to the page.
  3. 3
    Remember to denote the areas of the tags with the use of the <p>, </br> and </form> tags.
  4. Define a Selectable List in HTML Step 5.jpg
    4
    Denote a label for the item using the <p><nowiki> tag into the code.<br><br>[[Image:Define a Selectable List in HTML Step 4.jpg|center|550px]] # Type the <nowiki><select> tag to denote this type of list exists to the browser.
  5. Define a Selectable List in HTML Step 6.jpg
    5
    Press Enter.
  6. Define a Selectable List in HTML Step 7.jpg
    6
    Type the <option value="shortexplanation2denoteitem"> tag.
  7. Define a Selectable List in HTML Step 8.jpg
    7
    Type the text that you want your visitor to see displayed in the list.
  8. Define a Selectable List in HTML Step 9.jpg
    8
    Type the concluding tag for the option you wrote using the </option>
  9. Define a Selectable List in HTML Step 10.jpg
    9
    Repeat the steps from type the <option> tag downward for each item you'd like to include in the list.
  10. Define a Selectable List in HTML Step 11.jpg
    10
    Type the conclusionary tag for the selection/drop-down box using the <nowiki</select></nowiki> tag.
  11. Define a Selectable List in HTML Step 12.jpg
    11
    Type the </form> tag to conclude the form.
    Ad

Article Info

Categories: HTML

Recent edits by: Chris

Ad

Thanks to all authors for creating a page that has been read 1,527 times.

Was this article accurate?

YesNo

Contribute
to wikiHow!

Edit this article