Nonce from above. #2678

git-svn-id: https://develop.svn.wordpress.org/trunk@3759 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren
2006-05-02 22:36:06 +00:00
parent b96cd6f60c
commit fcfda4db13
30 changed files with 100 additions and 72 deletions

View File

@@ -2,7 +2,7 @@
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']) )
@@ -69,7 +69,7 @@ foreach ($theme_names as $theme_name) {
$author = $themes[$theme_name]['Author'];
$screenshot = $themes[$theme_name]['Screenshot'];
$stylesheet_dir = $themes[$theme_name]['Stylesheet Dir'];
$activate_link = "themes.php?action=activate&template=$template&stylesheet=$stylesheet";
$activate_link = wp_nonce_url("themes.php?action=activate&template=$template&stylesheet=$stylesheet", 'switch-theme' . $template);
?>
<div class="available-theme">
<h3><a href="<?php echo $activate_link; ?>"><?php echo "$title $version"; ?></a></h3>