Changeset 1393 for trunk/bp-core.php
- Timestamp:
- 04/23/2009 09:14:12 AM (17 years ago)
- File:
-
- 1 edited
-
trunk/bp-core.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/bp-core.php
r1391 r1393 23 23 if ( !defined( 'CUSTOM_USER_META_TABLE' ) ) 24 24 define( 'CUSTOM_USER_META_TABLE', $wpdb->base_prefix . 'usermeta' ); 25 26 /* Load the language file */ 27 if ( file_exists( BP_PLUGIN_DIR . '/bp-languages/buddypress-' . get_locale() . '.mo' ) ) 28 load_textdomain( 'buddypress', BP_PLUGIN_DIR . '/bp-languages/buddypress-' . get_locale() . '.mo' ); 25 29 26 30 /* Load the files containing functions that we globally will need. */ … … 241 245 } 242 246 add_action( 'admin_menu', 'bp_core_check_installed' ); 243 244 /**245 * bp_core_load_textdomain()246 *247 * Load a global text domain regardless of blog specific settings.248 * This stops the admin bar translating to the local blog language for a user.249 *250 * @package BuddyPress Core251 * @uses load_textdomain() Loads the localization file.252 */253 function bp_core_load_textdomain() {254 if ( defined( 'WPLANG' ) )255 $locale = WPLANG;256 else257 $locale = 'en_US';258 259 $locale = apply_filters( 'bp_core_buddypress_locale', $locale );260 261 if ( file_exists( BP_PLUGIN_DIR . '/bp-languages/buddypress-' . $locale . '.mo' ) )262 load_textdomain( 'buddypress', BP_PLUGIN_DIR . '/bp-languages/buddypress-' . $locale . '.mo' );263 }264 add_action( 'plugins_loaded', 'bp_core_load_textdomain', 1 );265 247 266 248 /**
Note: See TracChangeset
for help on using the changeset viewer.