How to create a button link in HTML

Would you like to add a so-called button link to your website? A button link or a link button, whatever you prefer, can be created by means of an <a> element which is styled wit CSS. A second option to create such a button is to design a form which includes an input field defined by a ‘submit’ type. The latter solution doesn’t require a button style because the standard style will be applied. Please find below the two button link examples:

Example 1

<a href="http://www.google.com" class="button">Visit Google</a>
Example 2

<form action="http://google.com">
<input type="submit" value="Visit Google">
</form>


Was this useful?