I'm creating a website using VS code and I want to create a button that when clicked will redirect to another page on the website.
I want to jump to a new page by clicking the "MENU" button. I've created a new file for the page I want to redirect, just not sure how to get "MENU" to act as a button and take me there. I'm using JavaScript and HTML/CSS in VS code.
So I want the button to take me to MENU.js
I tried using HTML to create a button but it only works if I link to the URL. I also tried the following.
MENU
But it doesn't seem to work.
Why not just uselink tags
instead of button tags? Or for buttons use the
onclick
attribute:content