Opened 15 years ago
Closed 14 years ago
#2111 closed defect (bug) (duplicate)
Allow Creating Settings Sub nav reliably in Buddypress
Reported by: | sbrajesh | Owned by: | |
---|---|---|---|
Milestone: | 1.5 | Priority: | minor |
Severity: | Version: | ||
Component: | Core | Keywords: | settings nav |
Cc: | sbrajesh |
Description
Currently there is no way in Buddypress to allow plugin developers reliably add their own submenu under settings.
The problem is "bp_core_new_subnav_item" uses wp action with priority 3 to set the screen functions while "bp_core_add_settings_nav" is called at "wp" action with priority 2. So A Plugin developer can not hook the submenu under settings with "wp" action priority greater 3, the screen functions will not be set.
The catch is, The menu can be set with "wp" action and priority 2, but it does not guarantee that the menu will be shown.
I will propose to either change the action for calling "bp_core_add_settings_nav" to bp_init or another easy way is just putting an action like do_action("bp_core_settings_nav") inside the function bp_core_add_settings_nav()
I am not attaching a patch, as I am not sure which method will be best, There may be some better option too.
to Make it more clear, I mean the settings Nav under User profile.