webmaster resources tips and articles
webmaster information

Path = Home : Form Tips : How To Create A Textarea Field For A Form

How To Create A Textarea Field For A Form

 

A Textarea field will accept any type of alphanumeric text entry.

<textarea name="textarea"></textarea>

 

Setting the size of the textarea

You can set the size of the textarea by specifying the number of columns wide and number of rows high that it will be.

<textarea name="textarea" cols="40" rows="5"></textarea>

 

Setting a background color and text font, size and color

<textarea name="textarea" cols="40" rows="5" style="color: #FF0000; font-family: Verdana; font-size: 12px; background-color: #FFFF66;"></textarea>

 

Adding default text to the textarea

You can add default text to the textarea. This is useful if for example you want a visitor to agree to terms and conditions before downloading a file.

<textarea name="textarea" cols="40" rows="5" style="color: #FF0000; font-family: Verdana; font-size: 12px; background-color: #FFFF66;">This is the default text for the textarea.</textarea>

 

 

© janim.net 2000 - 2007 All rights reserved