Changeset 34972
- Timestamp:
- 10/08/2015 11:08:40 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/embed-functions.php
r34971 r34972 525 525 526 526 /** 527 * Filter the allowed minimum widthfor the oEmbed response.527 * Filter the allowed minimum and maximum widths for the oEmbed response. 528 528 * 529 529 * @since 4.4.0 530 530 * 531 * @param int $width The minimum width. Defaults to 200. 532 */ 533 $minwidth = apply_filters( 'oembed_minwidth', 200 ); 534 535 /** 536 * Filter the allowed maximum width for the oEmbed response. 537 * 538 * @since 4.4.0 539 * 540 * @param int $width The maximum width. Defaults to 600. 541 */ 542 $maxwidth = apply_filters( 'oembed_maxwidth', 600 ); 543 544 if ( $width < $minwidth ) { 545 $width = $minwidth; 546 } else if ( $width > $maxwidth ) { 547 $width = $maxwidth; 531 * @param array $min_max_width { 532 * Minimum and maximum widths for the oEmbed response. 533 * 534 * @type int $min Minimum width. Default 200. 535 * @type int $max Maximum width. Default 600. 536 * } 537 */ 538 $min_max_width = apply_filters( 'oembed_min_max_width', array( 539 'min' => 200, 540 'max' => 600 541 ) ); 542 543 if ( $width < $min_max_width['min'] ) { 544 $width = $min_max_width['min']; 545 } elseif ( $width > $min_max_width['max'] ) { 546 $width = $min_max_width['max']; 548 547 } 549 548
Note: See TracChangeset
for help on using the changeset viewer.