> Online tutorial : HTML button
Showing posts with label HTML button. Show all posts
Showing posts with label HTML button. Show all posts

HTML checkbox

Check Box
It is simplest component which is used particularly whemn we used to make selection of serveral options.
Syntx
<input type='checkbox' name='check' value='value of checkbox'>
Example

<html>
<head>
<title>
HTML checkbox
</title>
</head>
<body>
<form name='form1'>
<input type='checkbox' name='check' value='apple'>
<input type='checkbox' name='check' value='orange'>
</form>
</body>
</html>




Output


Apple


HTML textarea

Text Area
Text field is a form component which allows us to enter the single line text,what if we want to have multiple line text?Then you must use the text area components.
Syntx
&lttextarea cols='20' rows='20' name='myname'>
Example

<html>
<head>
<title>
HTML Textarea
</title>
</head>
<body>
<form name='form1'>
Enter the text<textarea cols='20' rows='20' name='myname'>
</textarea>
</form>
</body>
</html>







<br /> HTML Textarea<br />


Enter the text


Output

Enter the text


HTML button

Button
There are two buttons that can be created in HTML.one is called submit button.and other is reset button.

parameters of submit button
  • name:
    denotes the name of the submit the button.
  • value:
    It is writing some text on the text on button.
  • align:
    specifies the alignment of the buttons.
  • Example

    <html>
    <head>
    <title>
    HTML Button
    </title>
    </head>
    <body>
    <form name='form1'>
    <div align='left'>
    Enter the  fruit name
    <textarea cols="40" rows="6">
    <input type='submit' name='' value='Submit'>
    <input type='reset' name='check' value='reset'>
    </div>
    </form>
    </body>
    </html>
Output