Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
01/27/2011 06:42:12 AM (14 years ago)
Author:
johnjamesjacoby
Message:

Move $bp_pages global into $bp->pages global. Check empty() on table_prefix, root_domain, and site_options to allow manual overrides.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-core/bp-core-catchuri.php

    r3917 r3947  
    2727 */
    2828function bp_core_set_uri_globals() {
    29     global $bp, $bp_pages;
    30     global $bp_unfiltered_uri, $bp_unfiltered_uri_offset;
     29    global $bp, $bp_unfiltered_uri, $bp_unfiltered_uri_offset;
    3130    global $current_blog;
    3231
     
    4342
    4443    // Fetch all the WP page names for each component
    45     if ( empty( $bp_pages ) )
    46         $bp_pages = bp_core_get_page_names();
     44    if ( empty( $bp->pages ) )
     45        $bp->pages = bp_core_get_page_names();
    4746
    4847    // Ajax or not?
     
    119118
    120119    // Find a match within registered BuddyPress controlled WP pages (check members first)
    121     foreach ( (array)$bp_pages as $page_key => $bp_page ) {
     120    foreach ( (array)$bp->pages as $page_key => $bp_page ) {
    122121        if ( in_array( $bp_page->name, (array)$bp_uri ) ) {
    123122            // Match found, now match the slug to make sure.
Note: See TracChangeset for help on using the changeset viewer.