I have this button for logging in to my website that is linked to a function in my javascript. But how can I also set the location to direct to another html page after logging in?
<div id="button_container">
<button onclick="login()">Login</button>
</div>
CodePudding user response:
Add to login()
window.location.href = 'login.html';
Check this thread for more info