Changeset 33666 for trunk/src/wp-admin/edit-form-advanced.php
- Timestamp:
- 08/20/2015 07:39:57 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/edit-form-advanced.php
r33641 r33666 85 85 $post_preview_url = apply_filters( 'preview_post_link', add_query_arg( 'preview', 'true', $permalink ), $post ); 86 86 87 $preview_link_html = $scheduled_link_html = $view_post_html = ''; 88 89 $viewable = is_post_type_viewable( $post_type_object ); 90 91 if ( $viewable ) { 92 // Preview link. 93 $preview_link_html = sprintf( ' <a target="_blank" href="%s">%s</a>', 94 esc_url( $post_preview_url ), 95 __( 'Preview post' ) 96 ); 97 98 // Scheduled preview link. 99 $scheduled_link_html = sprintf( ' <a target="_blank" href="%s">%s</a>', 100 esc_url( $permalink ), 101 __( 'Preview post' ) 102 ); 103 104 // View post link. 105 $view_post_html = sprintf( ' <a href="%s">">%</a>', 106 esc_url( $permalink ), 107 __( 'View post' ) 108 ); 109 } 110 111 /* translators: Publish box date format, see http://php.net/date */ 112 $scheduled_date = date_i18n( __( 'M j, Y @ H:i' ), strtotime( $post->post_date ) ); 87 113 $messages['post'] = array( 88 114 0 => '', // Unused. Messages start at index 1. 89 1 => sprintf( __('Post updated. <a href="%s">View post</a>'), esc_url( $permalink ) ),115 1 => __( 'Post updated.' ) . $view_post_html, 90 116 2 => __('Custom field updated.'), 91 117 3 => __('Custom field deleted.'), … … 93 119 /* translators: %s: date and time of the revision */ 94 120 5 => isset($_GET['revision']) ? sprintf( __('Post restored to revision from %s'), wp_post_revision_title( (int) $_GET['revision'], false ) ) : false, 95 6 => sprintf( __('Post published. <a href="%s">View post</a>'), esc_url( $permalink ) ),121 6 => __( 'Post published.' ) . $view_post_html, 96 122 7 => __('Post saved.'), 97 8 => sprintf( __('Post submitted. <a target="_blank" href="%s">Preview post</a>'), esc_url( $post_preview_url ) ), 98 9 => sprintf( __('Post scheduled for: <strong>%1$s</strong>. <a target="_blank" href="%2$s">Preview post</a>'), 99 /* translators: Publish box date format, see http://php.net/date */ 100 date_i18n( __( 'M j, Y @ H:i' ), strtotime( $post->post_date ) ), esc_url( $permalink ) ), 101 10 => sprintf( __('Post draft updated. <a target="_blank" href="%s">Preview post</a>'), esc_url( $post_preview_url ) ), 123 8 => __( 'Post submitted.' ) . $preview_link_html, 124 9 => sprintf( __( 'Post scheduled for: <strong>%1$s</strong>' ), $scheduled_date ) . $scheduled_link_html, 125 10 => __( 'Post draft updated.' ) . $preview_link_html, 102 126 ); 103 127 … … 509 533 <div class="inside"> 510 534 <?php 535 if ( $viewable ) : 511 536 $sample_permalink_html = $post_type_object->public ? get_sample_permalink_html($post->ID) : ''; 512 537 $shortlink = wp_get_shortlink($post->ID, 'post'); … … 526 551 <?php 527 552 } 553 endif; 528 554 ?> 529 555 </div>
Note: See TracChangeset
for help on using the changeset viewer.