Changeset 1017 for trunk/bp-core.php
- Timestamp:
- 02/04/2009 12:29:21 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/bp-core.php
r1012 r1017 55 55 require_once( 'bp-core/bp-core-activation.php' ); 56 56 57 /* Define the slug for member pages and the members directory (e.g. domain.com/[members] ) */57 /* Define the slug for member pages and the members directory (e.g. example.com/[members] ) */ 58 58 define( 'MEMBERS_SLUG', apply_filters( 'bp_members_slug', 'members' ) ); 59 59 … … 103 103 $bp['current_userid'] = $current_userid; 104 104 105 /* The domain for the user currently logged in. eg: http:// domain.com/members/andy */105 /* The domain for the user currently logged in. eg: http://example.com/members/andy */ 106 106 $bp['loggedin_domain'] = bp_core_get_user_domain($current_user->ID); 107 107 … … 109 109 $bp['current_domain'] = bp_core_get_user_domain($current_userid); 110 110 111 /* The component being used eg: http://andy. domain.com/ [profile] */111 /* The component being used eg: http://andy.example.com/ [profile] */ 112 112 $bp['current_component'] = $current_component; // type: string 113 113 114 /* The current action for the component eg: http://andy. domain.com/profile/ [edit] */114 /* The current action for the component eg: http://andy.example.com/profile/ [edit] */ 115 115 $bp['current_action'] = $current_action; // type: string 116 116 117 /* The action variables for the current action eg: http://andy. domain.com/profile/edit/ [group] / [6] */117 /* The action variables for the current action eg: http://andy.example.com/profile/edit/ [group] / [6] */ 118 118 $bp['action_variables'] = $action_variables; // type: array 119 119 120 /* Only used where a component has a sub item, e.g. groups: http://andy. domain.com/groups/ [my-group] / home - manipulated in the actual component not in catch uri code.*/120 /* Only used where a component has a sub item, e.g. groups: http://andy.example.com/groups/ [my-group] / home - manipulated in the actual component not in catch uri code.*/ 121 121 $bp['current_item'] = ''; // type: string 122 122 123 /* The default component to use if none are set and someone visits: http://andy. domain.com/ */123 /* The default component to use if none are set and someone visits: http://andy.example.com/ */ 124 124 $bp['default_component'] = 'profile'; 125 125 … … 197 197 user_id int(11) NOT NULL, 198 198 item_id int(11) NOT NULL, 199 secondary_item_id int(11) ,199 secondary_item_id int(11) NOT NULL, 200 200 component_name varchar(75) NOT NULL, 201 201 component_action varchar(75) NOT NULL, … … 241 241 if ( is_site_admin() ) { 242 242 /* Need to check db tables exist, activate hook no-worky in mu-plugins folder. */ 243 if ( ( $wpdb->get_var(" show tables like'%" . $bp['core']['table_name_notifications'] . "%'") == false ) || ( get_site_option('bp-core-db-version') < BP_CORE_DB_VERSION ) )243 if ( ( $wpdb->get_var("SHOW TABLES LIKE '%" . $bp['core']['table_name_notifications'] . "%'") == false ) || ( get_site_option('bp-core-db-version') < BP_CORE_DB_VERSION ) ) 244 244 bp_core_install(); 245 245 } … … 263 263 if ( is_site_admin() ) { 264 264 /* Add the administration tab under the "Site Admin" tab for site administrators */ 265 add_submenu_page( 'wpmu-admin.php', __( "BuddyPress", 'buddypress'), __("BuddyPress", 'buddypress'), 1, "bp_core_admin_settings", "bp_core_admin_settings");265 add_submenu_page( 'wpmu-admin.php', __('BuddyPress', 'buddypress'), __('BuddyPress', 'buddypress'), 1, 'bp_core_admin_settings', 'bp_core_admin_settings' ); 266 266 } 267 267 } … … 272 272 * 273 273 * Checks to see if a component's URL should be in the root, not under a member page: 274 * eg: http:// domain.com/groups/the-group NOT http://domain.com/members/andy/groups/the-group274 * eg: http://example.com/groups/the-group NOT http://example.com/members/andy/groups/the-group 275 275 * 276 276 * @package BuddyPress Core … … 326 326 * 327 327 * Returns the domain for the passed user: 328 * e.g. http:// domain.com/members/andy/328 * e.g. http://example.com/members/andy/ 329 329 * 330 330 * @package BuddyPress Core … … 338 338 if ( !$user_id ) return; 339 339 340 $ud = get_userdata( $user_id);340 $ud = get_userdata( $user_id ); 341 341 342 342 return $bp['root_domain'] . '/' . MEMBERS_SLUG . '/' . $ud->user_login . '/'; … … 347 347 * 348 348 * Returns the domain for the root blog. 349 * eg: http:// domain.com/ OR https://domain.com349 * eg: http://example.com/ OR https://example.com 350 350 * 351 351 * @package BuddyPress Core … … 367 367 * 368 368 * Returns the user id for the user that is currently being viewed. 369 * eg: http://andy. domain.com/ or http://domain.com/andy/369 * eg: http://andy.example.com/ or http://example.com/andy/ 370 370 * 371 371 * @package BuddyPress Core … … 527 527 * 528 528 * Example of a root component: 529 * Groups: http:// domain.com/groups/group-name530 * http://community. domain.com/groups/group-name531 * http:// domain.com/wpmu/groups/group-name529 * Groups: http://example.com/groups/group-name 530 * http://community.example.com/groups/group-name 531 * http://example.com/wpmu/groups/group-name 532 532 * 533 533 * Example of a component that is NOT a root component: 534 * Friends: http:// domain.com/members/andy/friends535 * http://community. domain.com/members/andy/friends536 * http:// domain.com/wpmu/members/andy/friends534 * Friends: http://example.com/members/andy/friends 535 * http://community.example.com/members/andy/friends 536 * http://example.com/wpmu/members/andy/friends 537 537 * 538 538 * @package BuddyPress Core … … 670 670 * 671 671 * Returns a HTML formatted link for a user with the user's full name as the link text. 672 * eg: <a href="http://andy. domain.com/">Andy Peatling</a>672 * eg: <a href="http://andy.example.com/">Andy Peatling</a> 673 673 * Optional parameters will return just the name, or just the URL, or disable "You" text when 674 674 * user matches the logged in user.
Note: See TracChangeset
for help on using the changeset viewer.