function myFunction() {
location.replace("https://www.w3schools.com")
}
in the script tag
<button onclick='myFunction()'>Submit</button>
in the html
Any idea why this very basic command doesn’t work?
Blancer.com Tutorials and projects
Freelance Projects, Design and Programming Tutorials
function myFunction() {
location.replace("https://www.w3schools.com")
}
in the script tag
<button onclick='myFunction()'>Submit</button>
in the html
Any idea why this very basic command doesn’t work?