Ticket #729: post.diff
| File post.diff, 1.8 kB (added by bthale, 1 year ago) |
|---|
-
post.php
old new 66 66 break; 67 67 68 68 case 'edit': 69 validateToken($_REQUEST['token'], 'post.php', 'edit', (int)$_REQUEST['post'] );69 validateToken($_REQUEST['token'], 'post.php', 'edit', (int)$_REQUEST['post'], true); 70 70 $title = __('Edit'); 71 71 72 72 require_once('admin-header.php'); … … 92 92 break; 93 93 94 94 case 'editattachment': 95 validateToken($_REQUEST['token'], 'post.php', 'editattachment', (int)$_REQUEST['post_ID'] );95 validateToken($_REQUEST['token'], 'post.php', 'editattachment', (int)$_REQUEST['post_ID'],true); 96 96 97 97 $post_id = (int) $_POST['post_ID']; 98 98 … … 112 112 add_post_meta($post_id, '_wp_attachment_metadata', $newmeta); 113 113 114 114 case 'editpost': 115 validateToken($_REQUEST['token'], 'post.php', 'editpost', (int)$_REQUEST['post_ID'] );115 validateToken($_REQUEST['token'], 'post.php', 'editpost', (int)$_REQUEST['post_ID'],true); 116 116 $post_ID = (int) $_POST['post_ID']; 117 117 check_admin_referer('update-post_' . $post_ID); 118 118 … … 190 190 191 191 $comment = (int) $_GET['comment']; 192 192 193 validateToken($_REQUEST['token'], 'post.php', 'editcomment', $comment );193 validateToken($_REQUEST['token'], 'post.php', 'editcomment', $comment, true); 194 194 if ( ! $comment = get_comment($comment) ) 195 195 die(sprintf(__('Oops, no comment with this ID. <a href="%s">Go back</a>!'), 'javascript:history.go(-1)')); 196 196 … … 210 210 $comment = (int) $_GET['comment']; 211 211 $p = (int) $_GET['p']; 212 212 213 validateToken($_REQUEST['token'], 'post.php', 'confirmdeletecomment', $comment );213 validateToken($_REQUEST['token'], 'post.php', 'confirmdeletecomment', $comment,true); 214 214 if ( ! $comment = get_comment($comment) ) 215 215 die(sprintf(__('Oops, no comment with this ID. <a href="%s">Go back</a>!'), 'edit.php')); 216 216
