public function run($arguments) { $arguments = Ithemes_Sync_Functions::merge_defaults($arguments, $this->default_arguments); backupbuddy_api::getBackupStatus($arguments['serial']); return; }
private static function _verb_getBackupStatus() { $backupSerial = pb_backupbuddy::_POST('serial'); pb_backupbuddy::status('details', '*** End Remote Backup Log section', $backupSerial); // Place at end of log. backupbuddy_api::getBackupStatus($backupSerial); // echos out. Use $returnRaw = true for remote_api call for this special verb that does not return json. // Fix missing WP cron constant. if (!defined('WP_CRON_LOCK_TIMEOUT')) { define('WP_CRON_LOCK_TIMEOUT', 60); // In seconds } // Try to force cron to run so that we can push the backup along. spawn_cron(time() + 150); // Adds > 60 seconds to get around once per minute cron running limit. }
<?php if (!is_admin()) { die('Access denied.'); } // IMPORTANT: MUST provide 3rd param, backup serial ID, when using pb_backupbuddy::status() within this function for it to show for this backup. $serial = trim(pb_backupbuddy::_POST('serial')); $serial = str_replace('/\\', '', $serial); $initRetryCount = (int) trim(pb_backupbuddy::_POST('initwaitretrycount')); $specialAction = pb_backupbuddy::_POST('specialAction'); $sqlFile = pb_backupbuddy::_POST('sqlFile'); backupbuddy_api::getBackupStatus($serial, $specialAction, $initRetryCount, $sqlFile, $echo = true); die;