本文整理汇总了PHP中backupbuddy_core::periodic_cleanup方法的典型用法代码示例。如果您正苦于以下问题:PHP backupbuddy_core::periodic_cleanup方法的具体用法?PHP backupbuddy_core::periodic_cleanup怎么用?PHP backupbuddy_core::periodic_cleanup使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类backupbuddy_core
的用法示例。
在下文中一共展示了backupbuddy_core::periodic_cleanup方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: housekeeping
function housekeeping()
{
if (!class_exists('backupbuddy_core')) {
require_once pb_backupbuddy::plugin_path() . '/classes/core.php';
}
backupbuddy_core::periodic_cleanup();
}
示例2:
if (pb_backupbuddy::_POST('reset_defaults') == $plugin_slug) {
if (call_user_func('pb_' . $plugin_slug . '::reset_options', true) === true) {
pb_backupbuddy::alert('Plugin settings have been reset to defaults for plugin `' . $data['name'] . '`.');
} else {
pb_backupbuddy::alert('Unable to reset plugin settings. Verify you are running the latest version.');
}
}
?>
<?php
}
// end plugin_information().
// User forced cleanup.
if (pb_backupbuddy::_GET('cleanup_now') != '') {
pb_backupbuddy::alert('Performing cleanup procedures now.');
backupbuddy_core::periodic_cleanup(0);
// clean up everything.
}
// Reset log.
if (pb_backupbuddy::_GET('reset_log') != '') {
if (file_exists($log_file)) {
@unlink($log_file);
}
if (file_exists($log_file)) {
// Didnt unlink.
pb_backupbuddy::alert('Unable to clear log file. Please verify permissions on file `' . $log_file . '`.');
} else {
// Unlinked.
pb_backupbuddy::alert('Cleared log file.');
}
}