HTML CSS JS

HOW TO SET HTML BUTTONS AS LINKS

<button onclick="location='http://site.com'">   BUTTON LINK </button>

JAVASCRIPT REDIRECT

01

<form action="http://site.com">   <input type="submit" value="GO"/> </form>

SUBMIT FORM

02

<form action="http://site.com">   <input type="submit" value="GO"/>   <input type="submit"       value="ANOTHER SITE"       formaction="http://sitez.com/"/> </form>

FORM ACTION

03

<a href="http://site.com">   <button>Go to Site</button> </a>

WRAP BUTTON IN LINK

04

THE CSS .linkbtn {  display: inline-block; padding: 10px;  margin: 5px; background: #8a110b;  color: #fff; text-decoration: none; }

CSS BUTTON

05

THE HTML <a class="linkbtn" href="http://site.com">   Looks like button, but is a link. </a>