HTML Buttons

An HTML button in its simplest form can be created using code below

<button>Click Me!</button>

Unlike buttons created using the input tag, button tag buttons can contain images and text. The bare bones button above is of very little use. A more complete version would appear like this

<button class="classname" id="AName" type="text" disabled="disabled" onclick="WhenClicked()"

While button elements are amenable to styling, what can be accomplished leaves much to be desired. This limitation can be overcome by abandoning buttons intrinsic to the browser and using CSS + HTML to create your own buttons instead. We discuss this technique in detail here.

Jump To...

Colophon