Do you have to do something special to redirect someone with a submit button to another page? (like a registration on a site) | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Do you have to do something special to redirect someone with a submit button to another page? (like a registration on a site)

I'm new to coding and I'm trying to understand a lot of things at once, at least the HTMl part for now. I'll be going to CSS and PHP after it. I'd appreciate if someone experienced would explain this to me and if someone would be willing to give me some contact info if i want to ask more questions. Thank you in advance

28th Apr 2019, 7:49 AM
Razvan Burcea
Razvan Burcea - avatar
1 Answer
+ 1
You can link the button to a JS function which redirects you. function redir() { window.location = "URL HERE"; } That should do it. If you're wondering how to make a button which executes said function, here it is: <button onclick="redir()">Redirect me!</button>
6th May 2019, 8:21 PM
inxanedev!
inxanedev! - avatar