Skip to content

Commit

Permalink
Ensure the caption shortcode outputs a valid HTML ID.
Browse files Browse the repository at this point in the history
fixes #33179.

Built from https://develop.svn.wordpress.org/trunk@33489


git-svn-id: http://core.svn.wordpress.org/trunk@33456 1a063a9b-81f0-0310-95a4-ce76da25c4cd
  • Loading branch information
helen committed Jul 29, 2015
1 parent bf9d148 commit d22adb0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion wp-includes/media.php
Original file line number Diff line number Diff line change
Expand Up @@ -896,7 +896,7 @@ function img_caption_shortcode( $attr, $content = null ) {
return $content;

if ( ! empty( $atts['id'] ) )
$atts['id'] = 'id="' . esc_attr( $atts['id'] ) . '" ';
$atts['id'] = 'id="' . esc_attr( sanitize_html_class( $atts['id'] ) ) . '" ';

$class = trim( 'wp-caption ' . $atts['align'] . ' ' . $atts['class'] );

Expand Down
2 changes: 1 addition & 1 deletion wp-includes/version.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
*
* @global string $wp_version
*/
$wp_version = '4.3-beta4-33488';
$wp_version = '4.3-beta4-33489';

/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
Expand Down

0 comments on commit d22adb0

Please sign in to comment.