Isn't there a method that I can use with onclick to display a different page?

I thought something with link() would work, but no go.

Something like this:
HTML Code:
<!DOCTYPE html>
<html>
<head>
<script type="text/javascript">
function logon() {
    // redirect here
}
</script>
</head
<body>
    <button  onclick="logon()">Logon</button> 
</body>
</html>
EDIT:

Found it!

location.replace()

Thanks for your time.