Hi All. I have an online form with text boxes, other form fields, and a submit button. When a user clicks the final submit button, I need a message box to say "Would you like to mark this record as complete?" - with both yes/no buttons on it. When 'yes' is selected, it loads 'complete.cfm'. When 'no' is selected, it loads 'not_complete.cfm'.
I'm using the following but it doesn't seem to pick up all the variables from the previous form... IE: #form.varname#, etc... Please advise.
-------------------------
<SCRIPT LANGUAGE="JavaScript">
<!--
function confirmRedirect(prompt, okURL, cancelURL)
{
var confirmResult;
// ask the user to chose either OK or Cancel
confirmResult = confirm(prompt);
// switch to a new URL based on the user's choice
if (confirmResult) {
window.location = okURL;
} else {
window.location = cancelURL;
}
}
// -->
</SCRIPT>
.
.
.
.
<form action="finish.cfm" method="POST">
.
.
.
.
<INPUT TYPE="button" VALUE="Submit Finished Form" onClick="confirmRedirect('Select Yes to mark this as complete!','complete.cfm','not_complete.cfm')">
-------------------------
Please advise if you can... Thanks a bunch!!!! It kinda urgent!
I'm using the following but it doesn't seem to pick up all the variables from the previous form... IE: #form.varname#, etc... Please advise.
-------------------------
<SCRIPT LANGUAGE="JavaScript">
<!--
function confirmRedirect(prompt, okURL, cancelURL)
{
var confirmResult;
// ask the user to chose either OK or Cancel
confirmResult = confirm(prompt);
// switch to a new URL based on the user's choice
if (confirmResult) {
window.location = okURL;
} else {
window.location = cancelURL;
}
}
// -->
</SCRIPT>
.
.
.
.
<form action="finish.cfm" method="POST">
.
.
.
.
<INPUT TYPE="button" VALUE="Submit Finished Form" onClick="confirmRedirect('Select Yes to mark this as complete!','complete.cfm','not_complete.cfm')">
-------------------------
Please advise if you can... Thanks a bunch!!!! It kinda urgent!