Changeset 3917 for trunk/bp-core/bp-core-hooks.php
- Timestamp:
- 01/25/2011 08:58:56 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/bp-core/bp-core-hooks.php
r3874 r3917 7 7 add_action( 'bp_loaded', 'bp_include', 2 ); 8 8 9 add_action( 'wp', 'bp_actions', 2 ); 10 11 add_action( 'wp', 'bp_screens', 2 ); 9 12 10 13 /** Init **********************************************************************/ 11 14 12 15 // Attach bp_init to WordPress init 13 add_action( 'init', 'bp_init');16 add_action( 'init', 'bp_init' ); 14 17 15 18 // Parse the URI and set globals 16 add_action( 'bp_init', 'bp_core_set_uri_globals',2 );19 add_action( 'bp_init', 'bp_core_set_uri_globals', 2 ); 17 20 18 21 // Setup component globals 19 add_action( 'bp_init', 'bp_setup_globals', 4 ); 20 21 // Setup root directories for components 22 add_action( 'bp_init', 'bp_setup_root_components', 6 ); 22 add_action( 'bp_init', 'bp_setup_globals', 4 ); 23 23 24 24 // Setup the navigation menu 25 add_action( 'bp_init', 'bp_setup_nav',8 );25 add_action( 'bp_init', 'bp_setup_nav', 8 ); 26 26 27 27 // Setup widgets 28 add_action( 'bp_init', 'bp_setup_widgets',8 );28 add_action( 'bp_init', 'bp_setup_widgets', 8 ); 29 29 30 30 // Setup admin bar 31 add_action( 'bp_loaded', 'bp_core_load_admin_bar');31 add_action( 'bp_loaded', 'bp_core_load_admin_bar' ); 32 32 33 /** The hooks *****************************************************************/ 34 35 /** 36 * Include files on this action 37 */ 38 function bp_include() { 39 do_action( 'bp_include' ); 40 } 41 42 /** 43 * Setup global variables and objects 44 */ 45 function bp_setup_globals() { 46 do_action( 'bp_setup_globals' ); 47 } 48 49 /** 50 * Set navigation elements 51 */ 52 function bp_setup_nav() { 53 do_action( 'bp_setup_nav' ); 54 } 55 56 /** 57 * Set the page title 58 */ 59 function bp_setup_title() { 60 do_action( 'bp_setup_title' ); 61 } 62 63 /** 64 * Register widgets 65 */ 66 function bp_setup_widgets() { 67 do_action( 'bp_register_widgets' ); 68 } 69 70 /** 71 * Initlialize code 72 */ 73 function bp_init() { 74 do_action( 'bp_init' ); 75 } 76 77 /** 78 * Attached to plugins_loaded 79 */ 80 function bp_loaded() { 81 do_action( 'bp_loaded' ); 82 } 83 84 /** 85 * Attach potential template actions 86 */ 87 function bp_actions() { 88 do_action( 'bp_actions' ); 89 } 90 91 /** 92 * Attach potential template screens 93 */ 94 function bp_screens() { 95 do_action( 'bp_screens' ); 96 } 33 97 34 98 ?>
Note: See TracChangeset
for help on using the changeset viewer.