You should all know this is inline scripting and is not a good practice at all...with that said you should definitively use javascript or jQuery for this type of thing:
HTML
<!DOCTYPE html> <html> <head> <meta charset="ISO-8859-1"> <title>Online Student Portal</title> </head> <body> <form action=""> <input type="button" id="myButton" value="Add"/> </form> </body> </html> JQuery
var button_my_button = "#myButton"; $(button_my_button).click(function(){ window.location.href='Students.html'; }); Javascript
//get a reference to the element var myBtn = document.getElementById('myButton'); //add event listener myBtn.addEventListener('click', function(event) { window.location.href='Students.html'; }); See comments why avoid inline scriptingwhy avoid inline scripting and also why inline scripting is bad