Changeset 24408 for trunk/wp-admin/includes/post.php
- Timestamp:
- 06/05/2013 03:01:59 AM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/includes/post.php
r24388 r24408 1203 1203 } 1204 1204 1205 if ( $locked && ( $sendback = wp_get_referer() ) && 1206 false === strpos( $sendback, 'post.php' ) && false === strpos( $sendback, 'post-new.php' ) ) { 1207 1208 $sendback_text = __('Go back'); 1209 } else { 1210 $sendback = admin_url( 'edit.php' ); 1211 1212 if ( 'post' != $post->post_type && ( $post_type_object = get_post_type_object( $post->post_type ) ) ) { 1213 $sendback .= '?post_type=' . $post->post_type; 1214 $sendback_text = sprintf( _x('Go to All %s', 'post type general name: Posts, Pages, etc.'), $post_type_object->labels->name ); 1215 } else { 1216 $sendback_text = __('Go to All Posts'); 1217 } 1218 } 1219 1205 1220 $hidden = $locked ? '' : ' hidden'; 1206 1221 … … 1230 1245 <?php do_action( 'post_lock_text', $post ); ?> 1231 1246 <p> 1232 <a class="button" href="<?php echo esc_url( wp_get_referer() ); ?>"><?php _e('Go back'); ?></a>1247 <a class="button" href="<?php echo esc_url( $sendback ); ?>"><?php echo $sendback_text; ?></a> 1233 1248 <a class="button<?php echo $tab_last; ?>" href="<?php echo esc_url( $preview_link ); ?>"><?php _e('Preview'); ?></a> 1234 1249 <?php … … 1255 1270 </p> 1256 1271 <?php do_action( 'post_lock_text', $post ); ?> 1257 <p><a class="button button-primary wp-tab-last" href="<?php echo esc_url( admin_url('edit.php') ); ?>"><?php _e('Go to All Posts'); ?></a></p>1272 <p><a class="button button-primary wp-tab-last" href="<?php echo esc_url( $sendback ); ?>"><?php echo $sendback_text; ?></a></p> 1258 1273 </div> 1259 1274 <?php
Note: See TracChangeset
for help on using the changeset viewer.