X-Git-Url: https://scripts.mit.edu/gitweb/autoinstalls/wordpress.git/blobdiff_plain/784f914b1e4b1c62d6657e86397c2e83bcee4295..16e7b37c7914d753890c1a05a9335f3b43751eb8:/wp-admin/includes/meta-boxes.php diff --git a/wp-admin/includes/meta-boxes.php b/wp-admin/includes/meta-boxes.php index bf877c3d..c26ced42 100644 --- a/wp-admin/includes/meta-boxes.php +++ b/wp-admin/includes/meta-boxes.php @@ -13,7 +13,7 @@ * @param array $args { * Array of arguments for building the post submit meta box. * - * @type string $id Meta box ID. + * @type string $id Meta box 'id' attribute. * @type string $title Meta box title. * @type callable $callback Meta box display callback. * @type array $args Extra meta box arguments. @@ -32,7 +32,7 @@ function post_submit_meta_box( $post, $args = array() ) {
- +
@@ -74,9 +74,9 @@ do_action( 'post_submitbox_minor_actions', $post );
-
- - + post_status ) { case 'private': _e('Privately Published'); @@ -98,11 +98,12 @@ switch ( $post->post_status ) { ?> post_status || 'private' == $post->post_status || $can_publish ) { ?> -post_status ) { ?>style="display:none;" class="edit-post-status hide-if-no-js"> +post_status ) { ?>style="display:none;" class="edit-post-status hide-if-no-js" role="button">
- post_status ) : ?> post_status, 'publish' ); ?> value='publish'> post_status ) : ?> @@ -144,7 +145,7 @@ if ( 'private' == $post->post_status ) { echo esc_html( $visibility_trans ); ?> - +
@@ -157,7 +158,7 @@ echo esc_html( $visibility_trans ); ?> ID ) ); ?> />
/>
-
+
/>

@@ -170,18 +171,22 @@ echo esc_html( $visibility_trans ); ?>

ID ) { if ( 'future' == $post->post_status ) { // scheduled for publishing at a future date + /* translators: Post date information. 1: Date on which the post is currently scheduled to be published */ $stamp = __('Scheduled for: %1$s'); } elseif ( 'publish' == $post->post_status || 'private' == $post->post_status ) { // already published + /* translators: Post date information. 1: Date on which the post was published */ $stamp = __('Published on: %1$s'); } elseif ( '0000-00-00 00:00:00' == $post->post_date_gmt ) { // draft, 1 or more saves, no date specified $stamp = __('Publish immediately'); } elseif ( time() < strtotime( $post->post_date_gmt . ' +0000' ) ) { // draft, 1 or more saves, future date specified + /* translators: Post date information. 1: Date on which the post is to be published */ $stamp = __('Schedule for: %1$s'); } else { // draft, 1 or more saves, date specified + /* translators: Post date information. 1: Date on which the post is to be published */ $stamp = __('Publish on: %1$s'); } $date = date_i18n( $datef, strtotime( $post->post_date ) ); @@ -192,7 +197,10 @@ if ( 0 != $post->ID ) { if ( ! empty( $args['args']['revisions_count'] ) ) : ?>
- ' . number_format_i18n( $args['args']['revisions_count'] ) . '' ); ?> + ' . number_format_i18n( $args['args']['revisions_count'] ) . '' ); + ?>
- +
@@ -252,14 +260,14 @@ if ( !in_array( $post->post_status, array('publish', 'future', 'private') ) || 0 if ( $can_publish ) : if ( !empty($post->post_date_gmt) && time() < strtotime( $post->post_date_gmt . ' +0000' ) ) : ?> - + - + - + @@ -290,14 +298,15 @@ function attachment_submit_meta_box( $post ) {
- +
%1$s'); $date = date_i18n( $datef, strtotime( $post->post_date ) ); ?> @@ -334,7 +343,7 @@ function attachment_submit_meta_box( $post ) {
- +
@@ -353,7 +362,7 @@ function attachment_submit_meta_box( $post ) { * @param array $box { * Post formats meta box arguments. * - * @type string $id Meta box ID. + * @type string $id Meta box 'id' attribute. * @type string $title Meta box title. * @type callable $callback Meta box display callback. * @type array $args Extra meta box arguments. @@ -394,7 +403,7 @@ function post_format_meta_box( $post, $box ) { * @param array $box { * Tags meta box arguments. * - * @type string $id Meta box ID. + * @type string $id Meta box 'id' attribute. * @type string $title Meta box title. * @type callable $callback Meta box display callback. * @type array $args { @@ -430,16 +439,18 @@ function post_tags_meta_box( $post, $box ) {
-

+

labels->separate_items_with_commas; ?>

+ +

labels->no_terms; ?>

-

labels->choose_from_most_used; ?>

+

post_type); - if ( $post_type_object->hierarchical ) { + if ( is_post_type_hierarchical( $post->post_type ) ) : $dropdown_args = array( 'post_type' => $post->post_type, 'exclude_tree' => $post->ID, @@ -798,7 +808,7 @@ function page_attributes_meta_box($post) { ); /** - * Filter the arguments used to generate a Pages drop-down element. + * Filters the arguments used to generate a Pages drop-down element. * * @since 3.3.0 * @@ -809,20 +819,20 @@ function page_attributes_meta_box($post) { */ $dropdown_args = apply_filters( 'page_attributes_dropdown_pages_args', $dropdown_args, $post ); $pages = wp_dropdown_pages( $dropdown_args ); - if ( ! empty($pages) ) { + if ( ! empty($pages) ) : ?> -

- +

post_type && 0 != count( get_page_templates( $post ) ) && get_option( 'page_for_posts' ) != $post->ID ) { - $template = !empty($post->page_template) ? $post->page_template : false; + endif; // end empty pages check + endif; // end hierarchical check. + + if ( count( get_page_templates( $post ) ) > 0 && get_option( 'page_for_posts' ) != $post->ID ) : + $template = ! empty( $post->page_template ) ? $post->page_template : false; ?> -

- - +post_type ); ?> - -

-

-post_type && get_current_screen()->get_help_tabs() ) { ?> -

- +post_type, 'page-attributes' ) ) : ?> +

+ +post_type && get_current_screen()->get_help_tabs() ) : ?> +

+
- +
@@ -909,9 +919,9 @@ if ( !empty($_GET['action']) && 'edit' == $_GET['action'] && current_user_can('m
link_id) ) { ?> - + - +
@@ -1013,7 +1023,7 @@ function xfn_check( $class, $value = '', $deprecated = '' ) { global $link; if ( !empty( $deprecated ) ) - _deprecated_argument( __FUNCTION__, '0.0' ); // Never implemented + _deprecated_argument( __FUNCTION__, '0.0.0' ); // Never implemented $link_rel = isset( $link->link_rel ) ? $link->link_rel : ''; // In PHP 5.3: $link_rel = $link->link_rel ?: ''; $rels = preg_split('/\s+/', $link_rel);