I need to focus node when onClose event. but always focused clicked button.
$.alert({
title: 'title',
content: 'message,
onClose : function () {
$('input[name="title"]').focus();
}
});
By default jQuery-confirm keeps track of the last focused element when it is opened, and when it is closed, it returns the last focused element to focus.
So work around for that:
Example: