1 restore.php restore_results_page()

Displays results of the restore script with any accompanying errors.

File

core/restore.php, line 181
Administrative page for restoring backup database and configuration files.

Code

function restore_results_page() {
  restore_task_list();

  if ($_GET['success']) {
    backdrop_set_title('Restore success');
    $output = '<p>' . st('The backup was successfully restored.') . '</p>';

    if (settings_get('restore_free_access')) {
      // Note this does not use backdrop_set_message() because session handling
      // is not initialized on restore.php.
      $output .= '<p>' . st("Reminder: Don't forget to set the !variable value in your !file file back to !value.", array(
        '!variable' => "<code>\$settings['restore_free_access']</code>",
        '!file' => '<code>settings.php</code>',
        '!value' => '<code>FALSE</code>',
      )) . '</p>';
    }

    $output .= '<p>' . l(st('Return to your site'), '<front>') . '</p>';
  }
  else {
    backdrop_set_title('Restore failure');
    $output = '<p>' . st('The restore process failed. Check the online documentation or reach out to the Backdrop community for help.') . '</p>';
  }

  return $output;
}