Uname: Linux premium294.web-hosting.com 4.18.0-553.45.1.lve.el8.x86_64 #1 SMP Wed Mar 26 12:08:09 UTC 2025 x86_64
Software: LiteSpeed
PHP version: 8.1.32 [ PHP INFO ] PHP os: Linux
Server Ip: 104.21.48.1
Your Ip: 216.73.216.223
User: mjbynoyq (1574) | Group: mjbynoyq (1570)
Safe Mode: OFF
Disable Function:
NONE

name : global-admin-script.js
/*! dup admin script */
jQuery(document).ready(function ($) {
    $('.dpro-admin-notice[data-to-dismiss]').each(function () {
        var notice = $(this);
        var notice_to_dismiss = notice.data('to-dismiss');

        notice.find('.notice-dismiss').on('click', function (event) {
            event.preventDefault();
            $.post(ajaxurl, {
                action: 'duplicator_pro_admin_notice_to_dismiss',
                notice: notice_to_dismiss,
                nonce: dup_pro_global_script_data.nonce_admin_notice_to_dismiss
            });
        });
    });

    function dupDashboardUpdate() {
        jQuery.ajax({
            type: "POST",
            url: dup_pro_global_script_data.ajaxurl,
            dataType: "json",
            data: {
                action: 'duplicator_pro_dashboad_widget_info',
                nonce: dup_pro_global_script_data.nonce_dashboard_widged_info
            },
            success: function (result, textStatus, jqXHR) {
                if (result.success) {
                    $('#duplicator_dashboard_widget .dup-last-backup-info').html(result.data.funcData.lastBackupInfo);

                    if (result.data.funcData.isRunning) {
                        $('#duplicator_dashboard_widget #dup-pro-create-new').addClass('disabled');
                    } else {
                        $('#duplicator_dashboard_widget #dup-pro-create-new').removeClass('disabled');
                    }
                }
            },
            complete: function() {
                setTimeout(
                    function(){
                        dupDashboardUpdate();
                    }, 
                    5000
                );
            }
        });
    }
    
    if ($('#duplicator_dashboard_widget').length) {
        dupDashboardUpdate();

        $('#duplicator_dashboard_widget #dup-dash-widget-section-recommended').on('click', function (event) {
            event.stopPropagation();
            
            $(this).closest('.dup-section-recommended').fadeOut();

            jQuery.ajax({
                type: "POST",
                url: dup_pro_global_script_data.ajaxurl,
                dataType: "json",
                data: {
                    action: 'duplicator_pro_dismiss_recommended_plugin',
                    nonce: dup_pro_global_script_data.nonce_dashboard_widged_dismiss_recommended
                },
                success: function (result, textStatus, jqXHR) {
                    // do nothing
                }
            });
        });
    }

    $('#screen-meta-links, #screen-meta').prependTo('#dup-meta-screen');
    $('#screen-meta-links').show();
});
© 2025 XylotrechusZ