update_update_page

Versions
4.7 – 5
update_update_page()

Code

./update.php, line 377

<?php
function update_update_page() {
  // Set the installed version so updates start at the correct place.
  foreach ($_POST['start'] as $module => $version) {
    drupal_set_installed_schema_version($module, $version - 1);
    $updates = drupal_get_schema_versions($module);
    $max_version = max($updates);
    if ($version <= $max_version) {
      foreach ($updates as $update) {
        if ($update >= $version) {
          $_SESSION['update_remaining'][] = array('module' => $module, 'version' => $update);
        }
      }
    }
  }

  // Keep track of total number of updates
  if (isset($_SESSION['update_remaining'])) {
    $_SESSION['update_total'] = count($_SESSION['update_remaining']);
  }

  if ($_POST['has_js']) {
    return update_progress_page();
  }
  else {
    return update_progress_page_nojs();
  }
}
?>
Login or register to post comments
 
 

All source code and documentation on this site is released under the terms of the GNU General Public License, version 2 and later. Drupal is a registered trademark of Dries Buytaert.