Changeset 26231
- Timestamp:
- 11/15/2013 10:28:57 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/post.php
r26230 r26231 119 119 case 'postajaxpost': 120 120 case 'post': 121 // Check nonce and capabilities 122 $nonce = $_REQUEST['_wpnonce']; 123 $error_msg = false; 124 if ( ! wp_verify_nonce( $nonce, 'add-post' ) ) 125 $error_msg = 'Unable to submit this form, please refresh and try again.'; 126 127 if ( ! current_user_can( 'edit_posts' ) ) 128 $error_msg = "Oops, you don't have access to add new drafts."; 129 121 check_admin_referer( 'add-' . $post_type ); 130 122 $post_id = 'postajaxpost' == $action ? edit_post() : write_post(); 131 132 redirect_post($post_id); 123 redirect_post( $post_id ); 133 124 exit(); 134 125 break;
Note: See TracChangeset
for help on using the changeset viewer.