Skip to:
Content

BuddyPress.org

Changeset 392 for trunk/bp-core.php


Ignore:
Timestamp:
10/12/2008 11:58:11 PM (17 years ago)
Author:
apeatling
Message:

Fixed catch-uri functions so that BuddyPress no longer has to be installed in the root of a site.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-core.php

    r391 r392  
    4242    global $current_user, $current_component, $current_action;
    4343    global $action_variables;
    44 
     44   
    4545    /* The user ID of the user who is currently logged in. */
    4646    $bp['loggedin_userid'] = $current_user->ID;
     
    10341034    global $bp;
    10351035   
    1036     if ( !is_user_logged_in() )
     1036    if ( !is_user_logged_in() || !get_usermeta( $bp['loggedin_userid'], 'last_activity') )
    10371037        return false;
    10381038   
     
    11111111add_action( 'get_comment_author_link', 'bp_core_replace_comment_author_link', 10, 4 );
    11121112
     1113/**
     1114 * bp_core_get_site_path()
     1115 *
     1116 * Get the path of of the current site.
     1117 *
     1118 * @package BuddyPress Core
     1119 * @global $comment WordPress comment global for the current comment.
     1120 * @uses bp_core_get_userlink_by_email() Fetches a userlink via email address.
     1121 */
     1122function bp_core_get_site_path() {
     1123    global $wpdb;
     1124   
     1125    return $wpdb->get_var( $wpdb->prepare( "SELECT path FROM {$wpdb->base_prefix}site WHERE id = 1") );
     1126}
    11131127
    11141128/**
Note: See TracChangeset for help on using the changeset viewer.