_redirect_to_about_wordpress

The timeline below displays how wordpress function _redirect_to_about_wordpress has changed across different WordPress versions. If a version is not listed, refer to the next available version below.

WordPress Version: 6.1

/**
 * Redirect to the About WordPress page after a successful upgrade.
 *
 * This function is only needed when the existing installation is older than 3.4.0.
 *
 * @since 3.3.0
 *
 * @global string $wp_version The WordPress version string.
 * @global string $pagenow    The filename of the current screen.
 * @global string $action
 *
 * @param string $new_version
 */
function _redirect_to_about_wordpress($new_version)
{
    global $wp_version, $pagenow, $action;
    if (version_compare($wp_version, '3.4-RC1', '>=')) {
        return;
    }
    // Ensure we only run this on the update-core.php page. The Core_Upgrader may be used in other contexts.
    if ('update-core.php' !== $pagenow) {
        return;
    }
    if ('do-core-upgrade' !== $action && 'do-core-reinstall' !== $action) {
        return;
    }
    // Load the updated default text localization domain for new strings.
    load_default_textdomain();
    // See do_core_upgrade().
    show_message(__('WordPress updated successfully.'));
    // self_admin_url() won't exist when upgrading from <= 3.0, so relative URLs are intentional.
    show_message('<span class="hide-if-no-js">' . sprintf(
        /* translators: 1: WordPress version, 2: URL to About screen. */
        __('Welcome to WordPress %1$s. You will be redirected to the About WordPress screen. If not, click <a href="%2$s">here</a>.'),
        $new_version,
        'about.php?updated'
    ) . '</span>');
    show_message('<span class="hide-if-js">' . sprintf(
        /* translators: 1: WordPress version, 2: URL to About screen. */
        __('Welcome to WordPress %1$s. <a href="%2$s">Learn more</a>.'),
        $new_version,
        'about.php?updated'
    ) . '</span>');
    echo '</div>';
    ?>
<script type="text/javascript">
window.location = 'about.php?updated';
</script>
	<?php 
    // Include admin-footer.php and exit.
    require_once ABSPATH . 'wp-admin/admin-footer.php';
    exit;
}

WordPress Version: 5.5

/**
 * Redirect to the About WordPress page after a successful upgrade.
 *
 * This function is only needed when the existing installation is older than 3.4.0.
 *
 * @since 3.3.0
 *
 * @global string $wp_version The WordPress version string.
 * @global string $pagenow
 * @global string $action
 *
 * @param string $new_version
 */
function _redirect_to_about_wordpress($new_version)
{
    global $wp_version, $pagenow, $action;
    if (version_compare($wp_version, '3.4-RC1', '>=')) {
        return;
    }
    // Ensure we only run this on the update-core.php page. The Core_Upgrader may be used in other contexts.
    if ('update-core.php' !== $pagenow) {
        return;
    }
    if ('do-core-upgrade' !== $action && 'do-core-reinstall' !== $action) {
        return;
    }
    // Load the updated default text localization domain for new strings.
    load_default_textdomain();
    // See do_core_upgrade().
    show_message(__('WordPress updated successfully.'));
    // self_admin_url() won't exist when upgrading from <= 3.0, so relative URLs are intentional.
    show_message('<span class="hide-if-no-js">' . sprintf(
        /* translators: 1: WordPress version, 2: URL to About screen. */
        __('Welcome to WordPress %1$s. You will be redirected to the About WordPress screen. If not, click <a href="%2$s">here</a>.'),
        $new_version,
        'about.php?updated'
    ) . '</span>');
    show_message('<span class="hide-if-js">' . sprintf(
        /* translators: 1: WordPress version, 2: URL to About screen. */
        __('Welcome to WordPress %1$s. <a href="%2$s">Learn more</a>.'),
        $new_version,
        'about.php?updated'
    ) . '</span>');
    echo '</div>';
    ?>
<script type="text/javascript">
window.location = 'about.php?updated';
</script>
	<?php 
    // Include admin-footer.php and exit.
    require_once ABSPATH . 'wp-admin/admin-footer.php';
    exit;
}

WordPress Version: 5.4

/**
 * Redirect to the About WordPress page after a successful upgrade.
 *
 * This function is only needed when the existing installation is older than 3.4.0.
 *
 * @since 3.3.0
 *
 * @global string $wp_version The WordPress version string.
 * @global string $pagenow
 * @global string $action
 *
 * @param string $new_version
 */
function _redirect_to_about_wordpress($new_version)
{
    global $wp_version, $pagenow, $action;
    if (version_compare($wp_version, '3.4-RC1', '>=')) {
        return;
    }
    // Ensure we only run this on the update-core.php page. The Core_Upgrader may be used in other contexts.
    if ('update-core.php' != $pagenow) {
        return;
    }
    if ('do-core-upgrade' != $action && 'do-core-reinstall' != $action) {
        return;
    }
    // Load the updated default text localization domain for new strings.
    load_default_textdomain();
    // See do_core_upgrade().
    show_message(__('WordPress updated successfully'));
    // self_admin_url() won't exist when upgrading from <= 3.0, so relative URLs are intentional.
    show_message('<span class="hide-if-no-js">' . sprintf(
        /* translators: 1: WordPress version, 2: URL to About screen. */
        __('Welcome to WordPress %1$s. You will be redirected to the About WordPress screen. If not, click <a href="%2$s">here</a>.'),
        $new_version,
        'about.php?updated'
    ) . '</span>');
    show_message('<span class="hide-if-js">' . sprintf(
        /* translators: 1: WordPress version, 2: URL to About screen. */
        __('Welcome to WordPress %1$s. <a href="%2$s">Learn more</a>.'),
        $new_version,
        'about.php?updated'
    ) . '</span>');
    echo '</div>';
    ?>
<script type="text/javascript">
window.location = 'about.php?updated';
</script>
	<?php 
    // Include admin-footer.php and exit.
    require_once ABSPATH . 'wp-admin/admin-footer.php';
    exit;
}

WordPress Version: 5.3

/**
 * Redirect to the About WordPress page after a successful upgrade.
 *
 * This function is only needed when the existing installation is older than 3.4.0.
 *
 * @since 3.3.0
 *
 * @global string $wp_version
 * @global string $pagenow
 * @global string $action
 *
 * @param string $new_version
 */
function _redirect_to_about_wordpress($new_version)
{
    global $wp_version, $pagenow, $action;
    if (version_compare($wp_version, '3.4-RC1', '>=')) {
        return;
    }
    // Ensure we only run this on the update-core.php page. The Core_Upgrader may be used in other contexts.
    if ('update-core.php' != $pagenow) {
        return;
    }
    if ('do-core-upgrade' != $action && 'do-core-reinstall' != $action) {
        return;
    }
    // Load the updated default text localization domain for new strings.
    load_default_textdomain();
    // See do_core_upgrade()
    show_message(__('WordPress updated successfully'));
    // self_admin_url() won't exist when upgrading from <= 3.0, so relative URLs are intentional.
    show_message('<span class="hide-if-no-js">' . sprintf(
        /* translators: 1: WordPress version, 2: URL to About screen. */
        __('Welcome to WordPress %1$s. You will be redirected to the About WordPress screen. If not, click <a href="%2$s">here</a>.'),
        $new_version,
        'about.php?updated'
    ) . '</span>');
    show_message('<span class="hide-if-js">' . sprintf(
        /* translators: 1: WordPress version, 2: URL to About screen. */
        __('Welcome to WordPress %1$s. <a href="%2$s">Learn more</a>.'),
        $new_version,
        'about.php?updated'
    ) . '</span>');
    echo '</div>';
    ?>
<script type="text/javascript">
window.location = 'about.php?updated';
</script>
	<?php 
    // Include admin-footer.php and exit.
    include ABSPATH . 'wp-admin/admin-footer.php';
    exit;
}

WordPress Version: 4.9

/**
 * Redirect to the About WordPress page after a successful upgrade.
 *
 * This function is only needed when the existing installation is older than 3.4.0.
 *
 * @since 3.3.0
 *
 * @global string $wp_version
 * @global string $pagenow
 * @global string $action
 *
 * @param string $new_version
 */
function _redirect_to_about_wordpress($new_version)
{
    global $wp_version, $pagenow, $action;
    if (version_compare($wp_version, '3.4-RC1', '>=')) {
        return;
    }
    // Ensure we only run this on the update-core.php page. The Core_Upgrader may be used in other contexts.
    if ('update-core.php' != $pagenow) {
        return;
    }
    if ('do-core-upgrade' != $action && 'do-core-reinstall' != $action) {
        return;
    }
    // Load the updated default text localization domain for new strings.
    load_default_textdomain();
    // See do_core_upgrade()
    show_message(__('WordPress updated successfully'));
    // self_admin_url() won't exist when upgrading from <= 3.0, so relative URLs are intentional.
    show_message('<span class="hide-if-no-js">' . sprintf(__('Welcome to WordPress %1$s. You will be redirected to the About WordPress screen. If not, click <a href="%2$s">here</a>.'), $new_version, 'about.php?updated') . '</span>');
    show_message('<span class="hide-if-js">' . sprintf(__('Welcome to WordPress %1$s. <a href="%2$s">Learn more</a>.'), $new_version, 'about.php?updated') . '</span>');
    echo '</div>';
    ?>
<script type="text/javascript">
window.location = 'about.php?updated';
</script>
	<?php 
    // Include admin-footer.php and exit.
    include ABSPATH . 'wp-admin/admin-footer.php';
    exit;
}

WordPress Version: 4.3

/**
 * Redirect to the About WordPress page after a successful upgrade.
 *
 * This function is only needed when the existing install is older than 3.4.0.
 *
 * @since 3.3.0
 *
 * @global string $wp_version
 * @global string $pagenow
 * @global string $action
 *
 * @param string $new_version
 */
function _redirect_to_about_wordpress($new_version)
{
    global $wp_version, $pagenow, $action;
    if (version_compare($wp_version, '3.4-RC1', '>=')) {
        return;
    }
    // Ensure we only run this on the update-core.php page. The Core_Upgrader may be used in other contexts.
    if ('update-core.php' != $pagenow) {
        return;
    }
    if ('do-core-upgrade' != $action && 'do-core-reinstall' != $action) {
        return;
    }
    // Load the updated default text localization domain for new strings.
    load_default_textdomain();
    // See do_core_upgrade()
    show_message(__('WordPress updated successfully'));
    // self_admin_url() won't exist when upgrading from <= 3.0, so relative URLs are intentional.
    show_message('<span class="hide-if-no-js">' . sprintf(__('Welcome to WordPress %1$s. You will be redirected to the About WordPress screen. If not, click <a href="%2$s">here</a>.'), $new_version, 'about.php?updated') . '</span>');
    show_message('<span class="hide-if-js">' . sprintf(__('Welcome to WordPress %1$s. <a href="%2$s">Learn more</a>.'), $new_version, 'about.php?updated') . '</span>');
    echo '</div>';
    ?>
<script type="text/javascript">
window.location = 'about.php?updated';
</script>
	<?php 
    // Include admin-footer.php and exit.
    include ABSPATH . 'wp-admin/admin-footer.php';
    exit;
}

WordPress Version: 4.0

/**
 * Redirect to the About WordPress page after a successful upgrade.
 *
 * This function is only needed when the existing install is older than 3.4.0.
 *
 * @since 3.3.0
 *
 */
function _redirect_to_about_wordpress($new_version)
{
    global $wp_version, $pagenow, $action;
    if (version_compare($wp_version, '3.4-RC1', '>=')) {
        return;
    }
    // Ensure we only run this on the update-core.php page. The Core_Upgrader may be used in other contexts.
    if ('update-core.php' != $pagenow) {
        return;
    }
    if ('do-core-upgrade' != $action && 'do-core-reinstall' != $action) {
        return;
    }
    // Load the updated default text localization domain for new strings.
    load_default_textdomain();
    // See do_core_upgrade()
    show_message(__('WordPress updated successfully'));
    // self_admin_url() won't exist when upgrading from <= 3.0, so relative URLs are intentional.
    show_message('<span class="hide-if-no-js">' . sprintf(__('Welcome to WordPress %1$s. You will be redirected to the About WordPress screen. If not, click <a href="%2$s">here</a>.'), $new_version, 'about.php?updated') . '</span>');
    show_message('<span class="hide-if-js">' . sprintf(__('Welcome to WordPress %1$s. <a href="%2$s">Learn more</a>.'), $new_version, 'about.php?updated') . '</span>');
    echo '</div>';
    ?>
<script type="text/javascript">
window.location = 'about.php?updated';
</script>
	<?php 
    // Include admin-footer.php and exit.
    include ABSPATH . 'wp-admin/admin-footer.php';
    exit;
}

WordPress Version: 3.7

/**
 * Redirect to the About WordPress page after a successful upgrade.
 *
 * This function is only needed when the existing install is older than 3.4.0.
 *
 * @since 3.3.0
 *
 */
function _redirect_to_about_wordpress($new_version)
{
    global $wp_version, $pagenow, $action;
    if (version_compare($wp_version, '3.4-RC1', '>=')) {
        return;
    }
    // Ensure we only run this on the update-core.php page. The Core_Upgrader may be used in other contexts.
    if ('update-core.php' != $pagenow) {
        return;
    }
    if ('do-core-upgrade' != $action && 'do-core-reinstall' != $action) {
        return;
    }
    // Load the updated default text localization domain for new strings
    load_default_textdomain();
    // See do_core_upgrade()
    show_message(__('WordPress updated successfully'));
    // self_admin_url() won't exist when upgrading from <= 3.0, so relative URLs are intentional.
    show_message('<span class="hide-if-no-js">' . sprintf(__('Welcome to WordPress %1$s. You will be redirected to the About WordPress screen. If not, click <a href="%2$s">here</a>.'), $new_version, 'about.php?updated') . '</span>');
    show_message('<span class="hide-if-js">' . sprintf(__('Welcome to WordPress %1$s. <a href="%2$s">Learn more</a>.'), $new_version, 'about.php?updated') . '</span>');
    echo '</div>';
    ?>
<script type="text/javascript">
window.location = 'about.php?updated';
</script>
	<?php 
    // Include admin-footer.php and exit
    include ABSPATH . 'wp-admin/admin-footer.php';
    exit;
}