I know it's possible to do either separately, but I am looking for a way to combine both the page redirection abiltiy and the passing of variables to it.
var fname, lname;
fname = document.getElementById("fname").value;
lname = document.getElementById("lname").value;
alert(fname + " " + lname);
First name: <input type="text" name="fname" id = "fname"/><br />
Last name: <input type="text" name="lname" id="lname"/><br />
<INPUT type="button" value="Submit" onClick= "send_alerts()"