Sh3ll
OdayForums


Server : LiteSpeed
System : Linux premium84.web-hosting.com 4.18.0-553.44.1.lve.el8.x86_64 #1 SMP Thu Mar 13 14:29:12 UTC 2025 x86_64
User : claqxcrl ( 523)
PHP Version : 8.1.32
Disable Function : NONE
Directory :  /home/claqxcrl/confenda.com/wp-content/plugins/poll-maker/admin/js/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /home/claqxcrl/confenda.com/wp-content/plugins/poll-maker/admin/js/admin.js
(function ($) {
    'use strict';

    $(document).on('click', '[data-slug="poll-maker"] .deactivate a', function () {
        swal({
            html: "<h2>Do you want to upgrade to Pro version or permanently delete the plugin?</h2><ul><li>Upgrade: Your data will be saved for upgrade.</li><li>Deactivate: Your data will be deleted completely.</li></ul>",
            footer: '<a href="" class="ays-poll-temporary-deactivation">Temporary deactivation</a>',
            type: 'question',
            showCancelButton: true,
            showCloseButton: true,
            allowOutsideClick: false,
            allowEscapeKey: false,
            allowEnterKey: false,
            confirmButtonColor: '#3085d6',
            cancelButtonColor: '#d33',
            confirmButtonText: 'Upgrade',
            cancelButtonText: 'Deactivate',
            confirmButtonClass: "ays-poll-upgrade-button"
        }).then( function(result) {
            var upgrade_plugin = false;
            if (result.value) upgrade_plugin = true;

            if( result.dismiss && result.dismiss == 'close' ){
                return false;
            }

            var data = {
                action: 'apm_deactivate_plugin_option_pmp',
                upgrade_plugin
            };
            $.ajax({
                url: apm_admin_ajax_obj.ajaxUrl,
                dataType: 'json',
                method: "post",
                data,
                success() {
                    location.replace($('[data-slug="poll-maker"] .deactivate a').attr('href'));
                }
            });
        });
        return false;
    });

    $(document).on('click', '.ays-poll-temporary-deactivation', function (e) {
        e.preventDefault();

        $(document).find('.ays-poll-upgrade-button').trigger('click');

    });

})(jQuery);

ZeroDay Forums Mini