Make WordPress Core


Ignore:
Timestamp:
06/30/2014 11:15:33 AM (11 years ago)
Author:
SergeyBiryukov
Message:

Pass $url parameter to wp_embed_defaults() and 'embed_defaults' filter.

props wpsmith, sabreuse, jacobdubail.
fixes #20151.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/media.php

    r28901 r28923  
    20832083 * @since 2.9.0
    20842084 *
     2085 * @param string $url Optional. The URL that should be embedded. Default empty.
     2086 *
    20852087 * @return array Default embed parameters.
    20862088 */
    2087 function wp_embed_defaults() {
     2089function wp_embed_defaults( $url = '' ) {
    20882090    if ( ! empty( $GLOBALS['content_width'] ) )
    20892091        $width = (int) $GLOBALS['content_width'];
     
    20992101     * @since 2.9.0
    21002102     *
    2101      * @param int $width  Width of the embed in pixels.
    2102      * @param int $height Height of the embed in pixels.
    2103      */
    2104     return apply_filters( 'embed_defaults', compact( 'width', 'height' ) );
     2103     * @param int    $width  Width of the embed in pixels.
     2104     * @param int    $height Height of the embed in pixels.
     2105     * @param string $url    The URL that should be embedded.
     2106     */
     2107    return apply_filters( 'embed_defaults', compact( 'width', 'height' ), $url );
    21052108}
    21062109
Note: See TracChangeset for help on using the changeset viewer.