HTML and CSS Reference
After a user inputs the requested information, buttons allow the user to put that information
into action. Most commonly, a submit input or submit button is used to process the data.
Users click the submit button to process data after filling out a form. The submit button is
created using the <input> element with a type attribute value of submit . The value
attribute is used to specify the text that appears within the button (see Figure 10.13 ).
1. <input type="submit" name="submit" value="Send" >
Figure 10.13 A submit button created by way of the <input> element with a type
attribute value of submit
As an <input> element, the submit button is self-contained and cannot wrap any other
content. If more control over the structure and design of the input is desired—along with
the ability to wrap other elements—the <button> element may be used.
The <button> element performs the same way as the <input> element with the type
attribute value of submit ; however, it includes opening and closing tags, which may wrap
other elements. By default, the <button> element acts as if it has a type attribute value
of submit , so the type attribute and value may be omitted from the <button> element
if you wish.
Rather than using the value attribute to control the text within the submit button, the text
that appears between the opening and closing tags of the <button> element will appear
1. <button name="submit">
2. <strong>Send Us</strong> a Message