From an admin page if the user is valid then the browser should go to another page.
When a user enters his user name and password, then clicks the OK button then another
To simply redirect a browser using javascript:
window.location.href = "http://example.com/new_url";
To redirect AND submit a form (i.e. login details), requires no javascript:
Submit