Make WordPress Core


Ignore:
Timestamp:
01/10/2006 03:06:48 AM (20 years ago)
Author:
matt
Message:

Better redirect back.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/upgrade.php

    r3186 r3420  
    6868
    6969    case 0:
     70    $goback = wp_specialchars($_SERVER['HTTP_REFERER'], 1);
    7071?>
    7172<p><?php _e('This file upgrades you from any previous version of WordPress to the latest. It may take a while though, so be patient.'); ?></p>
    72     <h2 class="step"><a href="upgrade.php?step=1"><?php _e('Upgrade WordPress &raquo;'); ?></a></h2>
     73    <h2 class="step"><a href="upgrade.php?step=1&amp;backto=<?php echo $goback; ?>"><?php _e('Upgrade WordPress &raquo;'); ?></a></h2>
    7374<?php
    7475    break;
     
    7980    upgrade_all();
    8081    wp_cache_flush();
     82
     83    if ( empty( $_GET['backto'] ) )
     84        $backto = __get_option('home');
     85    else
     86        $backto = wp_specialchars( $_GET['backto'] , 1 );
    8187?>
    8288<h2><?php _e('Step 1'); ?></h2>
    83     <p><?php printf(__("There's actually only one step. So if you see this, you're done. <a href='%s'>Have fun</a>!"), __get_option('home') . '/'); ?></p>
     89    <p><?php printf(__("There's actually only one step. So if you see this, you're done. <a href='%s'>Have fun</a>!"),  $backto); ?></p>
    8490
    8591<!--
Note: See TracChangeset for help on using the changeset viewer.