2 ms·
HTML forms submit to whatever URL you put in the “action” attribute, which could be an API endpoint, or code in the same file (a common ASP/PHP pattern), or ano
by gregjor 6y ago
HTML forms submit to whatever URL you put in the “action” attribute, which could be an API endpoint, or code in the same file (a common ASP/PHP pattern), or another file. You don’t need JS for that. Likewise a redirect is just an HTTP “Location” header sent to the browser, no JS needed for that, either.