Reputation: 47
Here i have following piece of code in javascript that popup a confirmation alert box wherein there are two button yes and no. On clicking yes it should go to given link but it give member not found error.
$.when(confirmationMsg(FINF_CONFIRM_CLEAR)).then(
function (confirm) {
if (confirm) {
frm.action = "associationRuleAnalyser.do?mode=associationRuleStartAnalyser";
frm.submit();
}
});
Expected output: On clicking yes it should redirect to the given link
Upvotes: 1
Views: 594
Reputation: 2095
Not really sure what frm is, but you could use the window.confirm method:
function submitdata() {
var r = confirm('Confirmation message');
if (r == true) {
window.open('http://www.yourpage.com');
} else {
alert('never mind');
}
return false;
}
Upvotes: 1