[buddypress-dev] What is the bp-core-catchuri logic?

Glenn Ansley glenn at glennansley.com
Thu Jul 17 17:30:24 GMT 2008


Hi,
I'm trying to create a new front-end menu that appears for users when they
are logged in. I've attempted to outline my problem very thoroughly below:

*Quick History
*My goal is to create a new level of navigation in the default Buddy Press
Theme*
*I found how to create the navigation easily enough using the bp_nav[] and
the bp_users_nav[] arrays.
I am now working on catching the actions via pretty URLs. I can't seem to
get the $current_action to register though.

*My Scenario*
My new menu should show *menu-parent* in the left-most sidebar with *
menu-child1*, *menuchild2*, *menuchild3*, and *menuchild4* in the middle
bar. The content associated with *menu-child1* should display as the default
page in the main content area.

*What is currently working
*The above scenario is working fine without any problems. I have
successfully created the menus and the default content by mimicking the same
programing logic (arrays and functions) used by the xprofile menu and pages.

*What is not working*
Selecting *menuchild2*, *menuchild3*, or *menuchild4* from the middle
options bar does not take me to the appropriate page, but instead, takes me
to WPMU's create a new blog page.
*
Why I think it's not working
*It appears to me that the default content is working correctly because the
$current_action variable is not set in the _catch_actions function (like the
xprofile_catch_action_function).
While trying to track this down, put a PHP die($bp_uri) function on line 19
in bp-core-catchuri.php directly under the $bp_uri variable.
When I select any default menu like Profile -> Edit Avatar I get the
expected uri : /profile/change-avatar
But if I select one of my new menu times like Menu-Parent -> Menu Child 1, I
get  /wp-signup.php?new=menu-child1 as the $bp_uri

*Question*
How does BP avoid this "new blog registration" redirect. Is it a DB
configuration. It seems to me that bp-core-catchuri.php is one of the first
scripts to fire off. I can't find for the life of me what I'm missing.

Thanks for bearing with me. I hope that someone might have an answer for me!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://comox.textdrive.com/pipermail/buddypress-dev/attachments/20080717/eaf001c1/attachment.htm


More information about the buddypress-dev mailing list