X-Git-Url: https://scripts.mit.edu/gitweb/autoinstalls/wordpress.git/blobdiff_plain/ff81ee6e8304a1982a3ec4f5b134764a29d502cf..7688c6ba71852cd89123b62b2d57683535e4702a:/wp-admin/themes.php?ds=sidebyside diff --git a/wp-admin/themes.php b/wp-admin/themes.php index a17ea3cd..8aa783aa 100644 --- a/wp-admin/themes.php +++ b/wp-admin/themes.php @@ -2,18 +2,18 @@ require_once('admin.php'); if ( isset($_GET['action']) ) { - check_admin_referer(); - + check_admin_referer('switch-theme_' . $_GET['template']); + if ('activate' == $_GET['action']) { if ( isset($_GET['template']) ) update_option('template', $_GET['template']); - + if ( isset($_GET['stylesheet']) ) update_option('stylesheet', $_GET['stylesheet']); - + do_action('switch_theme', get_current_theme()); - - header('Location: themes.php?activated=true'); + + wp_redirect('themes.php?activated=true'); exit; } } @@ -26,7 +26,7 @@ require_once('admin-header.php');
View site »'), get_bloginfo('home') . '/'); ?>
View site »'), get_bloginfo('url') . '/'); ?>
description; ?>
parent_theme) { ?>%2$s. The stylesheet files are located in %3$s
. %4$s uses templates from %5$s. Changes made to the templates will affect both themes.'), $ct->title, $ct->template_dir, $ct->stylesheet_dir, $ct->title, $ct->parent_theme); ?>