Changes from branches/3.1/wp-admin/includes/template.php at r18018 to trunk/wp-admin/includes/template.php at r18314
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/includes/template.php
r18018 r18314 426 426 <thead> 427 427 <tr> 428 <th class="left">' . _ _( 'Name' ) . '</th>428 <th class="left">' . _x( 'Name', 'meta name' ) . '</th> 429 429 <th>' . __( 'Value' ) . '</th> 430 430 </tr> … … 441 441 <thead> 442 442 <tr> 443 <th class="left"><?php _e ( 'Name' ) ?></th>443 <th class="left"><?php _ex( 'Name', 'meta name' ) ?></th> 444 444 <th><?php _e( 'Value' ) ?></th> 445 445 </tr> … … 536 536 <thead> 537 537 <tr> 538 <th class="left"><label for="metakeyselect"><?php _e ( 'Name' ) ?></label></th>538 <th class="left"><label for="metakeyselect"><?php _ex( 'Name', 'meta name' ) ?></label></th> 539 539 <th><label for="metavalue"><?php _e( 'Value' ) ?></label></th> 540 540 </tr> … … 943 943 // Grab the ones the user has manually sorted. Pull them out of their previous context/priority and into the one the user chose 944 944 if ( !$already_sorted && $sorted = get_user_option( "meta-box-order_$page" ) ) { 945 foreach ( $sorted as $box_context => $ids ) 946 foreach ( explode(',', $ids ) as $id )945 foreach ( $sorted as $box_context => $ids ) { 946 foreach ( explode(',', $ids ) as $id ) { 947 947 if ( $id ) 948 948 add_meta_box( $id, null, null, $page, $box_context, 'sorted' ); 949 } 950 } 949 951 } 950 952 $already_sorted = true; … … 962 964 $hidden_class = in_array($box['id'], $hidden) ? ' hide-if-js' : ''; 963 965 echo '<div id="' . $box['id'] . '" class="postbox ' . postbox_classes($box['id'], $page) . $hidden_class . '" ' . '>' . "\n"; 964 echo '<div class="handlediv" title="' . esc_attr__('Click to toggle') . '"><br /></div>'; 966 if ( 'dashboard_browser_nag' != $box['id'] ) 967 echo '<div class="handlediv" title="' . esc_attr__('Click to toggle') . '"><br /></div>'; 965 968 echo "<h3 class='hndle'><span>{$box['title']}</span></h3>\n"; 966 969 echo '<div class="inside">' . "\n"; … … 1628 1631 1629 1632 if ( !empty($post->post_password) ) 1630 $post_states[ ] = __('Password protected');1633 $post_states['protected'] = __('Password protected'); 1631 1634 if ( 'private' == $post->post_status && 'private' != $post_status ) 1632 $post_states[ ] = __('Private');1635 $post_states['private'] = __('Private'); 1633 1636 if ( 'draft' == $post->post_status && 'draft' != $post_status ) 1634 $post_states[ ] = __('Draft');1637 $post_states['draft'] = __('Draft'); 1635 1638 if ( 'pending' == $post->post_status && 'pending' != $post_status ) 1636 1639 /* translators: post state */ 1637 $post_states[ ] = _x('Pending', 'post state');1640 $post_states['pending'] = _x('Pending', 'post state'); 1638 1641 if ( is_sticky($post->ID) ) 1639 $post_states[ ] = __('Sticky');1642 $post_states['sticky'] = __('Sticky'); 1640 1643 1641 1644 $post_states = apply_filters( 'display_post_states', $post_states ); … … 1656 1659 } 1657 1660 1661 function _media_states( $post ) { 1662 $media_states = array(); 1663 $stylesheet = get_option('stylesheet'); 1664 1665 if ( current_theme_supports( 'custom-header') ) { 1666 $meta_header = get_post_meta($post->ID, '_wp_attachment_is_custom_header', true ); 1667 if ( ! empty( $meta_header ) && $meta_header == $stylesheet ) 1668 $media_states[] = __( 'Header Image' ); 1669 } 1670 1671 if ( current_theme_supports( 'custom-background') ) { 1672 $meta_background = get_post_meta($post->ID, '_wp_attachment_is_custom_background', true ); 1673 if ( ! empty( $meta_background ) && $meta_background == $stylesheet ) 1674 $media_states[] = __( 'Background Image' ); 1675 } 1676 1677 $media_states = apply_filters( 'display_media_states', $media_states ); 1678 1679 if ( ! empty( $media_states ) ) { 1680 $state_count = count( $media_states ); 1681 $i = 0; 1682 echo ' - '; 1683 foreach ( $media_states as $state ) { 1684 ++$i; 1685 ( $i == $state_count ) ? $sep = '' : $sep = ', '; 1686 echo "<span class='post-state'>$state$sep</span>"; 1687 } 1688 } 1689 } 1690 1658 1691 /** 1659 1692 * Convert a screen string to a screen object … … 1717 1750 if ( !empty($wp_current_screen_options) ) 1718 1751 $show_screen = true; 1752 1753 $show_screen = apply_filters('screen_options_show_screen', $show_screen, $screen); 1719 1754 1720 1755 ?> … … 1923 1958 } 1924 1959 1925 function screen_icon($screen = '') { 1960 function screen_icon( $screen = '' ) { 1961 echo get_screen_icon( $screen ); 1962 } 1963 1964 function get_screen_icon( $screen = '' ) { 1926 1965 global $current_screen, $typenow; 1927 1966 … … 1951 1990 } 1952 1991 1953 ?> 1954 <div id="icon-<?php echo $name; ?>" class="<?php echo $class; ?>"><br /></div> 1955 <?php 1992 return '<div id="icon-' . esc_attr( $name ) . '" class="' . $class . '"><br /></div>'; 1956 1993 } 1957 1994 … … 2190 2227 return $button; 2191 2228 } 2192
Note: See TracChangeset
for help on using the changeset viewer.