Add nonces to tag importers. Props xknown. fixes #4811
git-svn-id: http://svn.automattic.com/wordpress/trunk@5941 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
@@ -31,6 +31,9 @@ class UTW_Import {
|
||||
} else {
|
||||
$step = (int) $_GET['step'];
|
||||
}
|
||||
|
||||
if ( $step > 1 )
|
||||
check_admin_referer('import-utw');
|
||||
|
||||
// load the header
|
||||
$this->header();
|
||||
@@ -102,6 +105,7 @@ class UTW_Import {
|
||||
}
|
||||
|
||||
echo '<form action="admin.php?import=utw&step=2" method="post">';
|
||||
wp_nonce_field('import-utw');
|
||||
echo '<p class="submit"><input type="submit" name="submit" value="'.__('Step 2 »').'" /></p>';
|
||||
echo '</form>';
|
||||
echo '</div>';
|
||||
@@ -137,6 +141,7 @@ class UTW_Import {
|
||||
}
|
||||
|
||||
echo '<form action="admin.php?import=utw&step=3" method="post">';
|
||||
wp_nonce_field('import-utw');
|
||||
echo '<p class="submit"><input type="submit" name="submit" value="'.__('Step 3 »').'" /></p>';
|
||||
echo '</form>';
|
||||
echo '</div>';
|
||||
@@ -155,6 +160,7 @@ class UTW_Import {
|
||||
echo '<p>' . sprintf( __('Done! <strong>%s</strong> tags where added!'), $tags_added ) . '<br /></p>';
|
||||
|
||||
echo '<form action="admin.php?import=utw&step=4" method="post">';
|
||||
wp_nonce_field('import-utw');
|
||||
echo '<p class="submit"><input type="submit" name="submit" value="'.__('Step 4 »').'" /></p>';
|
||||
echo '</form>';
|
||||
echo '</div>';
|
||||
|
||||
Reference in New Issue
Block a user