Changeset 8577
- Timestamp:
- 08/06/2008 09:31:40 PM (17 years ago)
- Location:
- trunk/wp-admin
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/edit-form-advanced.php
r8576 r8577 119 119 <?php if ( current_user_can( 'publish_posts' ) ) : ?> 120 120 <p id="private-checkbox"><label for="post_status_private" class="selectit"><input id="post_status_private" name="post_status" type="checkbox" value="private" <?php checked($post->post_status, 'private'); ?> tabindex="4" /> <?php _e('Keep this post private') ?></label></p> 121 <p id="sticky-checkbox"><label for="sticky" class="selectit"><input id="sticky" name="sticky" type="checkbox" value="sticky" <?php checked(is_sticky($post->ID), true); ?> tabindex="4" /> <?php _e('Stick this post to the front page') ?></label></p> 121 <?php if ( current_user_can( 'edit_others_posts' ) ) : ?> 122 <p id="sticky-checkbox"><label for="sticky" class="selectit"><input id="sticky" name="sticky" type="checkbox" value="sticky" <?php checked(is_sticky($post->ID), true); ?> tabindex="4" /> <?php _e('Stick this post to the front page') ?></label></p> 123 <?php endif; ?> 122 124 <?php endif; ?> 123 125 <?php -
trunk/wp-admin/includes/post.php
r8546 r8577 162 162 wp_set_post_lock( $post_ID, $GLOBALS['current_user']->ID ); 163 163 164 if ( !empty($_POST['sticky']) ) 165 stick_post($post_ID); 166 else 167 unstick_post($post_ID); 164 if ( current_user_can( 'edit_others_posts' ) ) { 165 if ( !empty($_POST['sticky']) ) 166 stick_post($post_ID); 167 else 168 unstick_post($post_ID); 169 } 168 170 169 171 return $post_ID;
Note: See TracChangeset
for help on using the changeset viewer.