Changeset 21948 for trunk/wp-admin/includes/post.php
- Timestamp:
- 09/21/2012 10:52:54 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/includes/post.php
r21944 r21948 233 233 continue; 234 234 delete_meta( $key ); 235 } 236 } 237 238 // Attachment stuff 239 if ( 'attachment' == $post_data['post_type'] && isset( $post_data['_wp_attachment_image_alt'] ) ) { 240 $image_alt = get_post_meta( $post_ID, '_wp_attachment_image_alt', true ); 241 if ( $image_alt != stripslashes( $post_data['_wp_attachment_image_alt'] ) ) { 242 $image_alt = wp_strip_all_tags( stripslashes( $post_data['_wp_attachment_image_alt'] ), true ); 243 // update_meta expects slashed 244 update_post_meta( $post_ID, '_wp_attachment_image_alt', addslashes( $image_alt ) ); 235 245 } 236 246 } … … 1065 1075 list($permalink, $post_name) = get_sample_permalink($post->ID, $new_title, $new_slug); 1066 1076 1067 if ( 'publish' == $post->post_status) {1077 if ( 'publish' == get_post_status( $post ) ) { 1068 1078 $ptype = get_post_type_object($post->post_type); 1069 1079 $view_post = $ptype->labels->view_item;
Note: See TracChangeset
for help on using the changeset viewer.