Making WordPress.org

Changeset 4911


Ignore:
Timestamp:
02/16/2017 07:30:14 PM (8 years ago)
Author:
johnjamesjacoby
Message:

BuddyPress/bbPress: Set embed width to 515 (mostly for forums & posts)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/buddypress.org/public_html/wp-content/themes/bb-base/functions.php

    r4632 r4911  
    527527}
    528528add_action( 'init', 'bb_base_register_menus' );
     529
     530/**
     531 * Set embed width to 515 (mostly for forums & posts)
     532 */
     533function bb_base_embed_defaults( $min_max = array() ) {
     534    return array(
     535        'width'  => 515,
     536        'height' => min( ceil( 515 * 1.5 ), 1000 )
     537    );
     538}
     539add_filter( 'embed_defaults', 'bb_base_embed_defaults' );
Note: See TracChangeset for help on using the changeset viewer.