Skip to:
Content

BuddyPress.org

Ticket #3108: ticket.3108.2.diff

File ticket.3108.2.diff, 1.2 KB (added by ptahdunbar, 9 years ago)
  • bp-loader.php

     
    2020if ( !defined( 'BP_DB_VERSION' ) )
    2121        define( 'BP_DB_VERSION', 3706 );
    2222
    23 // Place your custom code (actions/filters) in a file called
    24 // '/plugins/bp-custom.php' and it will be loaded before anything else.
     23/**
     24 * Drop-in a bp-custom.php file within the plugins/ directory
     25 * to customize BuddyPress before it loads.
     26 */
    2527if ( file_exists( WP_PLUGIN_DIR . '/bp-custom.php' ) )
    2628        require_once( WP_PLUGIN_DIR . '/bp-custom.php' );
    2729
     30/**
     31 * Drop-in a functions-buddypress.php file within the active theme's directory
     32 * to customize BuddyPress before it loads.
     33 */
     34if ( file_exists( get_stylesheet_directory() . '/functions-buddypress.php' ) )
     35        require_once( get_stylesheet_directory() . '/functions-buddypress.php' );
     36
     37elseif ( file_exists( get_template_directory() . '/functions-buddypress.php' ) )
     38        require_once( get_template_directory() . '/functions-buddypress.php' );
     39
    2840// Define on which blog ID BuddyPress should run
    2941if ( !defined( 'BP_ROOT_BLOG' ) )
    3042        define( 'BP_ROOT_BLOG', 1 );