Merge pull request #1066 from yoavf/fix/edit-post-link-i18n

Prevent broken translations in some locales for the edit post link
This commit is contained in:
David A. Kennedy 2017-06-09 15:46:16 -04:00 committed by GitHub
commit 3aa7934d56
2 changed files with 6 additions and 6 deletions

View File

@ -84,9 +84,9 @@ function _s_entry_footer() {
edit_post_link(
sprintf(
/* translators: %s: Name of current post */
esc_html__( 'Edit %s', '_s' ),
the_title( '<span class="screen-reader-text">"', '"</span>', false )
/* translators: %s: Name of current post. Only visible to screen readers */
wp_kses( __( 'Edit <span class="screen-reader-text">%s</span>', '_s' ), array( 'span' => array( 'class' => array() ) ) ),
get_the_title()
),
'<span class="edit-link">',
'</span>'

View File

@ -30,9 +30,9 @@
<?php
edit_post_link(
sprintf(
/* translators: %s: Name of current post */
esc_html__( 'Edit %s', '_s' ),
the_title( '<span class="screen-reader-text">"', '"</span>', false )
/* translators: %s: Name of current post. Only visible to screen readers */
wp_kses( __( 'Edit <span class="screen-reader-text">%s</span>', '_s' ), array( 'span' => array( 'class' => array() ) ) ),
get_the_title()
),
'<span class="edit-link">',
'</span>'