Search Site          
 
Home  

Forms considerations

Most modern browsers can handle forms that stretch over different tables, but writing such forms is against all standards and is bad HTML. Unless you really can't avoid it, don't do it.

For example,

  <table>
  <tr><td>
     <form>
     <input type="text" name="something">
     <input type="radio" name"button1">
     <input type="radio" name"button2">
     </form>
  </tr></td>
  </table>
			

is fine, but

  <table>
    <tr><td>
       <form>
       <input type="text" name="something"<
    </tr></td>
  </table>
  <table>
    <tr><td>
       <input type="radio" name"button1">
       <input type="radio" name"button2">
       </form>
    </tr></td>
    </table>
			

is not.

Note that the input forms in search.htm can be changed at will. The default is drop-down menus, but nothing stops you from using radio buttons or hidden input or even text boxes. For instance, where search.htm says

  Results per page:
  <SELECT NAME="ps">
  <OPTION VALUE="10" SELECTED="$ps">10
  <OPTION VALUE="20" SELECTED="$ps">20
  <OPTION VALUE="50" SELECTED="$ps">50
  </SELECT>
			

you can very well substitute

  <input type="radio" name"ps" value="10">
  <input type="radio" name"ps" value="20" checked>
  <input type="radio" name"ps" value="50">
			

which will result in three radio buttons instead of a drop-down menu, with "20" as the default and the exact same functionality. What you obviously cannot do is provide multiple-choice menus like <type="checkbox"> or <select multiple>.

Note that you can also use the

  <input type="hidden" name="XX" value="YY">
  			

format if you want to set other defaults than the pre-defined and not allow the user to change them.




Copyright © 2000-2011 Lavtech.Com Corp.