• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

9. Forms > The <button> Tag

The <button> Tag

As we described earlier, you create an action button with traditional HTML or XHTML by including its type value in the standard <input> tag. For instance, the <input type=submit> form control creates a button that, when selected by the user, tells the browser to send the form’s contents to the processing server or to an email address (the mailto option). Display-wise, you don’t have any direct control over what that submit button looks like, beyond changing the default label “Submit” to some other word or short phrase (e.g., “Hit me” or “Outta here!”).

First introduced in the HTML 4.0 standard, the <button> tag acts the same as the <input> button, but it gives you more control over how the browser displays the element. In particular, all of the attributes you might use with the <input type=button> element are acceptable with the <button> tag.


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint