Embeds: Adjust the iframe title attribute for improved accessibility.

Changes the title attribute from `Embedded WordPress Post` to `"Post name" — site title`.

Props ramiy.
Fixes #35804.

git-svn-id: https://develop.svn.wordpress.org/trunk@36873 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Pascal Birchler
2016-03-07 09:59:02 +00:00
parent e9dbf32553
commit afdf1c9ec1
2 changed files with 16 additions and 2 deletions

View File

@@ -490,7 +490,14 @@ JS;
esc_url( $embed_url ),
absint( $width ),
absint( $height ),
esc_attr__( 'Embedded WordPress Post' )
esc_attr(
sprintf(
/* translators: 1: post title, 2: site name */
__( '“%1$s” — %2$s' ),
get_the_title( $post ),
get_bloginfo( 'name' )
)
)
);
/**