| Server IP : 38.190.208.107 / Your IP : 216.73.217.46 Web Server : nginx/1.28.1 System : Linux ht2026040333114 6.1.0-10-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.37-1 (2023-07-03) x86_64 User : root ( 0) PHP Version : 8.2.28 Disable Function : passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv,eval,assert,passthru,system,exec,shell_exec,popen,proc_open MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /www/wwwroot/wp.9/wp-content/plugins/duplicator/views/tools/diagnostics/ |
Upload File : |
<?php
use Duplicator\Core\Controllers\ControllersManager;
defined('ABSPATH') || defined('DUPXABSPATH') || exit;
wp_enqueue_script('dup-handlebars');
require_once(DUPLICATOR_PLUGIN_PATH . '/classes/utilities/class.u.scancheck.php');
require_once(DUPLICATOR_PLUGIN_PATH . '/classes/class.io.php');
$installer_files = DUP_Server::getInstallerFiles();
$package_name = (isset($_GET['package'])) ? esc_html($_GET['package']) : '';
$abs_path = duplicator_get_abs_path();
// For auto detect archive file name logic
if (empty($package_name)) {
$installer_file_path = $abs_path . '/' . 'installer.php';
if (file_exists($installer_file_path)) {
$installer_file_data = file_get_contents($installer_file_path);
if (preg_match("/const ARCHIVE_FILENAME = '(.*?)';/", $installer_file_data, $match)) {
$temp_archive_file = esc_html($match[1]);
$temp_archive_file_path = $abs_path . '/' . $temp_archive_file;
if (file_exists($temp_archive_file_path)) {
$package_name = $temp_archive_file;
}
}
}
}
$package_path = empty($package_name) ? '' : $abs_path . '/' . $package_name;
$txt_found = __('File Found: Unable to remove', 'duplicator');
$txt_removed = __('Removed', 'duplicator');
$nonce = wp_create_nonce('duplicator_cleanup_page');
$section = (isset($_GET['section'])) ? $_GET['section'] : '';
if ($section == "info" || $section == '') {
$_GET['action'] = isset($_GET['action']) ? $_GET['action'] : '';
switch ($_GET['action']) {
case 'tmp-cache':
if (!wp_verify_nonce($_REQUEST['_wpnonce'], 'duplicator_cleanup_page')) {
exit; // Get out of here bad nounce!
}
DUP_Package::tempFileCleanup(true);
?>
<div id="message" class="notice notice-success is-dismissible dup-wpnotice-box">
<p><b><?php _e('Build cache removed.', 'duplicator'); ?></b></p>
</div>
<?php
break;
}
}
$actionUrl = ControllersManager::getMenuLink(
ControllersManager::TOOLS_SUBMENU_SLUG,
'diagnostics',
null,
['section' => 'info']
);
?>
<form id="dup-settings-form" action="<?php echo esc_url($actionUrl); ?>" method="post">
<?php
wp_nonce_field('duplicator_settings_page', '_wpnonce', false);
include_once 'inc.data.php';
include_once 'inc.settings.php';
include_once 'inc.validator.php';
include_once 'inc.phpinfo.php';
?>
</form>