Create confirmations with JAlert (flwebsites.biz/jAlert/)

0

I'm using a plugin called JAlert v4 (available at link ) to create error messages, but I can not use it to create confirmation messages because the browser simply ignores the confirmation message, only executing what comes after it.

$("#form-cadProfessor").submit(function(event) {
    $.jAlert({
        'type': 'confirm',
        'confirmQuestion': 'Você deseja cadastrar este professor?',
        'confirmBtnText': 'Sim',
        'denyBtnText': 'Não',

        'onConfirm': function(e, btn){
                        if(!validarCampos()){
                            event.preventDefault();
                            return false;   
                        }
                     },

        'onDeny': function(e, btn){
                        event.preventDefault();
                        return false;   
                  }
    });
});

Could anyone help me solve this problem?

    
asked by anonymous 19.11.2016 / 05:38

0 answers