Changeset 19471
- Timestamp:
- 11/28/2011 10:58:51 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/includes/screen.php
r19468 r19471 234 234 * @access public 235 235 */ 236 public $action = '';236 public $action; 237 237 238 238 /** … … 388 388 return $hook_name; 389 389 390 $ action = $post_type = $taxonomy = null;390 $post_type = $taxonomy = null; 391 391 $is_network = $is_user = false; 392 $action = ''; 392 393 393 394 if ( $hook_name ) … … 401 402 $id = 'post'; // changes later. ends up being $base. 402 403 } else { 403 $last_four = substr( $id, -4 ); 404 if ( '.php' == $last_four ) { 404 if ( '.php' == substr( $id, -4 ) ) 405 405 $id = substr( $id, 0, -4 ); 406 $last_four = substr( $id, -4 ); 407 } 408 if ( '-add' == $last_four || '-new' == $last_four ) { 406 407 if ( 'post-new' == $id || 'link-add' == $id || 'media-new' == $id || 'user-new' == $id ) { 409 408 $id = substr( $id, 0, -4 ); 410 409 $action = 'add'; … … 422 421 423 422 $id = sanitize_key( $id ); 424 if ( 'edit- ' == substr( $id, 0, 5 ) ) {423 if ( 'edit-comments' != $id && 'edit-tags' != $id && 'edit-' == substr( $id, 0, 5 ) ) { 425 424 $maybe = substr( $id, 5 ); 426 425 if ( taxonomy_exists( $maybe ) ) { … … 486 485 $taxonomy = 'post_tag'; 487 486 $id = 'edit-' . $taxonomy; 488 break;489 case 'upload' :490 if ( null === $post_type )491 $post_type = 'attachment';492 487 break; 493 488 }
Note: See TracChangeset
for help on using the changeset viewer.