Changeset 42838
- Timestamp:
- 03/16/2018 08:18:48 PM (7 years ago)
- Location:
- branches/4.9
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/4.9
-
branches/4.9/src/wp-includes/media.php
r42669 r42838 1579 1579 $style = ''; 1580 1580 if ( $caption_width ) { 1581 $style = 'style=" max-width: ' . (int) $caption_width . 'px" ';1581 $style = 'style="width: ' . (int) $caption_width . 'px" '; 1582 1582 } 1583 1583 -
branches/4.9/tests/phpunit/tests/media.php
r41964 r42838 126 126 127 127 if ( current_theme_supports( 'html5', 'caption' ) ) { 128 $this->assertEquals( 1, preg_match_all( "/max-width: 20/", $result, $_r ) );128 $this->assertEquals( 1, preg_match_all( '/width: 20/', $result, $_r ) ); 129 129 } else { 130 $this->assertEquals( 1, preg_match_all( "/max-width: 30/", $result, $_r ) );130 $this->assertEquals( 1, preg_match_all( '/width: 30/', $result, $_r ) ); 131 131 } 132 132 } -
branches/4.9/tests/phpunit/tests/shortcode.php
r41724 r42838 478 478 array( 479 479 '[caption caption="test" width="2"]<div>hello</div>[/caption]', 480 '<div style=" max-width: 12px" class="wp-caption alignnone"><div>hello</div><p class="wp-caption-text">test</p></div>',480 '<div style="width: 12px" class="wp-caption alignnone"><div>hello</div><p class="wp-caption-text">test</p></div>', 481 481 ), 482 482 array(
Note: See TracChangeset
for help on using the changeset viewer.