etter
04-30-2003, 05:56 AM
Below you see what i have till now. This script calls a confirm window when you click the submit button. I want that when the user clicks ok, another php script is loaded in the browser window, but i don't know how to do this in javascript. Please help me!
<script language="JavaScript">
<!--
function confirm_entry()
{
input_box=confirm("Click OK or Cancel to Continue");
if (input_box==true)
{
// Output when OK is clicked
alert ("You clicked OK");
}
else
{
// Output when Cancel is clicked
alert ("You clicked cancel");
}
}
-->
</script>
<form onSubmit="confirm_entry()">
<input type="submit" >
</form>
<script language="JavaScript">
<!--
function confirm_entry()
{
input_box=confirm("Click OK or Cancel to Continue");
if (input_box==true)
{
// Output when OK is clicked
alert ("You clicked OK");
}
else
{
// Output when Cancel is clicked
alert ("You clicked cancel");
}
}
-->
</script>
<form onSubmit="confirm_entry()">
<input type="submit" >
</form>