JJJ (@johnjamesjacoby)

Forum Replies Created

Viewing 25 replies - 2,176 through 2,200 (of 2,213 total)

  • JJJ
    Keymaster

    @johnjamesjacoby

    Hmm this is an interesting scenario, one that I never made it around to checking since I always do my work as an Admin or KeyMaster.

    I did just check my install of 2.7rc1 and bbPress Alpha-2 and I do not experience this type of issue.

    I am assuming that you’ve checked the obvious stuff from all of the other integration topics here? Making sure your SECRET_KEY’s match and cookie domains are copied over, etc?


    JJJ
    Keymaster

    @johnjamesjacoby

    @elwagar: Conversely, once they are registered you can assign them a role by going to the bbPress admin, WordPress Integration, and remapping. I feel like a plug-in could help this registration laziness along, but I also think this should just work correctly right away.

    I actually had a similar issue years ago integrating phpBB 2.x and osCommerce together, trying to get one to work inside the other with cookies and what-not was a really big problem, one that I never really did get working 100% correctly.

    I have no experience with bbPress Live, but it might be worth looking into. CK posted a really nice SQL example on how to grab information without a plug-in, so if you can’t get that to work, you could always put in a little manual labor. ;)


    JJJ
    Keymaster

    @johnjamesjacoby

    Which versions of bbPress and WordPress are you using?

    Are you doing all of this logging in and out on the same computer?

    Have you tried manually deleting cookies and logging in again?

    What folders are WordPress and bbPress located in, relative to each other?


    JJJ
    Keymaster

    @johnjamesjacoby

    I am experiencing the same issue, and I think we all really can’t wait for this to work correctly.


    JJJ
    Keymaster

    @johnjamesjacoby

    @mvds: The idea is that logging into or out of either/or will do that action on both sides for a unified website function. If you log into or out of either, and it affects the other immediately, and you have admin access to both sides regardless of where you login, that’s a good thing. :)


    JJJ
    Keymaster

    @johnjamesjacoby

    Have you tried logging in and out of both your WordPress and bbPress installations and accessing both admin panels? I mean each combination each way.

    1. Log into WordPress; Check admin panel access and cookies; Log out of WordPress
    2. Log into bbPress; Check admin panel access and cookies; Log out of bbPress
    3. Log into WordPress; Check admin panel access and cookies; Log out of bbPress
    4. Log into bbPress; Check admin panel access and cookies; Log out of WordPress

    That is where the problem lies, and I have been running the most updated trunks of both bbPress and WordPress the entire time. :/


    JJJ
    Keymaster

    @johnjamesjacoby

    Short term, I was able to make this work by modifying 1 core WordPress file. This only allows for integration of the theme, but still does not allow access to the bbPress admin panel without changing the bb-config.php file back to original.

    It’s essentially a quick fix to get the theme working with all capabilities playing nicely.

    Basically I’m hard-coding the capability check from bbPress into WordPress. There should be a filter for this, but I’m not sure how to hook into it correctly without a mod or plug-in on the WordPress side.

    ~My fix is in no way a permanent solution. Auto-updating your WordPress installation will overwrite this fix.~


    In FILE wp-includes/capabilities.php:

    In the meta_map_cap function:

    Around Line 906:

    AFTER break;

    BEFORE default

    INSERT:

    /*
    
    */
    case 'write_post':
    $caps[] = 'write_posts';
    break;
    case 'edit_post':
    // edit_posts, edit_others_posts, edit_deleted, edit_closed, ignore_edit_lock
    if ( !$bb_post = bb_get_post( $args[0] ) ) {
    $caps[] = 'magically_provide_data_given_bad_input';
    return $caps;
    }
    if ( $user_id == $bb_post->poster_id )
    $caps[] = 'edit_posts';
    else
    $caps[] = 'edit_others_posts';
    if ( $bb_post->post_status == '1' )
    $caps[] = 'edit_deleted';
    if ( !topic_is_open( $bb_post->topic_id ) )
    $caps[] = 'edit_closed';
    $post_time = bb_gmtstrtotime( $bb_post->post_time );
    $curr_time = time() + 1;
    $edit_lock = bb_get_option( 'edit_lock' );
    if ( $edit_lock >= 0 && $curr_time - $post_time > $edit_lock * 60 )
    $caps[] = 'ignore_edit_lock';
    break;
    case 'delete_post' :
    // edit_deleted, delete_posts
    if ( !$bb_post = bb_get_post( $args[0] ) ) {
    $caps[] = 'magically_provide_data_given_bad_input';
    return $caps;
    }
    if ( 0 != $bb_post->post_status )
    $caps[] = 'edit_deleted';
    // NO BREAK
    case 'manage_posts' : // back compat
    $caps[] = 'delete_posts';
    break;
    case 'write_topic':
    $caps[] = 'write_topics';
    break;
    case 'edit_topic':
    // edit_closed, edit_deleted, edit_topics, edit_others_topics
    if ( !$topic = get_topic( $args[0] ) ) {
    $caps[] = 'magically_provide_data_given_bad_input';
    return $caps;
    }
    if ( !topic_is_open( $args[0]) )
    $caps[] = 'edit_closed';
    if ( '1' == $topic->topic_status )
    $caps[] = 'edit_deleted';
    if ( $user_id == $topic->topic_poster )
    $caps[] = 'edit_topics';
    else
    $caps[] = 'edit_others_topics';
    break;
    case 'move_topic' :
    $caps[] = 'move_topics';
    break;
    case 'stick_topic' :
    $caps[] = 'stick_topics';
    break;
    case 'close_topic' :
    $caps[] = 'close_topics';
    break;
    case 'delete_topic' :
    $caps[] = 'delete_topics';
    add_filter( 'get_topic_where', 'no_where', 9999 );
    if ( !$topic = get_topic( $args[0] ) ) {
    $caps[] = 'magically_provide_data_given_bad_input';
    return $caps;
    }
    if ( 0 != $topic->topic_status )
    $caps[] = 'edit_deleted';
    remove_filter( 'get_topic_where', 'no_where', 9999 );
    break;
    case 'manage_topics' :
    // back compat
    $caps[] = 'move_topics';
    $caps[] = 'stick_topics';
    $caps[] = 'close_topics';
    $caps[] = 'delete_topics';
    break;
    case 'add_tag_to':
    // edit_closed, edit_deleted, edit_tags;
    if ( !$topic = get_topic( $args[0] ) ) {
    $caps[] = 'magically_provide_data_given_bad_input';
    return $caps;
    }
    if ( !topic_is_open( $topic->topic_id ) )
    $caps[] = 'edit_closed';
    if ( '1' == $topic->topic_status )
    $caps[] = 'edit_deleted';
    $caps[] = 'edit_tags';
    break;
    case 'edit_tag_by_on':
    // edit_closed, edit_deleted, edit_tags, edit_others_tags
    if ( !$topic = get_topic( $args[1] ) ) {
    $caps[] = 'magically_provide_data_given_bad_input';
    return $caps;
    }
    if ( !topic_is_open( $topic->topic_id ) )
    $caps[] = 'edit_closed';
    if ( '1' == $topic->topic_status )
    $caps[] = 'edit_deleted';
    if ( $user_id == $args[0] )
    $caps[] = 'edit_tags';
    else
    $caps[] = 'edit_others_tags';
    break;
    case 'edit_user':
    // edit_profile, edit_users;
    if ( $user_id == $args[0] )
    $caps[] = 'edit_profile';
    else
    $caps[] = 'edit_users';
    break;
    case 'edit_favorites_of':
    // edit_favorites, edit_others_favorites;
    if ( $user_id == $args[0] )
    $caps[] = 'edit_favorites';
    else
    $caps[] = 'edit_others_favorites';
    break;
    case 'delete_forum':
    $caps[] = 'delete_forums';
    break;
    case 'change_user_password':
    // change_password, edit_users
    $caps[] = 'change_password';
    if ( $user_id != $args[0] )
    $caps[] = 'edit_users';
    break;
    /*
    */


    JJJ
    Keymaster

    @johnjamesjacoby

    Firstly, have you checked to make sure that your site paths are correct in both bbPress and WordPress? Since you shifted directories, the paths to those new directories need to be adjusted in the database.

    Secondly, are there normal user tables to go along with those weird empty ones? Part of the integration process is telling bbPress which tables to find your users in. Is it possible that you added an extra “_” on accident, and bbPress created those tables while it was looking for the real ones?


    JJJ
    Keymaster

    @johnjamesjacoby

    We’re all experiencing the same issue.

    Integration appears to be a little broken still.

    If you need to use the WP functions in your bbPress, that will break it further by not allowing you to access your bbPress admin panel at all.

    The problem looks like the bb_map_meta_cap filter is ignored when the WordPress functions are loaded in place of the bbPress ones.

    Some users have been able to resolve this by using a .htaccess file to redirect to the bbPress login and register page whenever an attempt to register or login is made through WordPress. That is the best fix at the moment if you do not require access to the WP functions.

    If you do require that access, then you will need to wait until a fix comes out for the issue I mentioned above. That’s where I am. :(


    JJJ
    Keymaster

    @johnjamesjacoby

    It seems like there are several issues here, and I’m not sure which is really the issue or which is a bug…

    Firstly, when integrated, bbPress wants to use the WordPress classes and functions where possible. Namely, the problem with capabilities lies currently with the difference in the WP_User->has_cap function.

    On the WordPress side of it, it is missing the global $wp_roles; and the corresponding check of those roles against the current capability to check.

    $caps = call_user_func_array( array(&$wp_roles, 'map_meta_cap'), $args );

    So I’m not sure if this is just a case of bbPress not keeping up with the WordPress user/role classes, or if this is WordPress not properly carrying over bbPress capabilities.

    Ugh…


    JJJ
    Keymaster

    @johnjamesjacoby

    I noticed this happening here and over at the WordPress.org forums, so there may have been some kind of a delay.


    JJJ
    Keymaster

    @johnjamesjacoby

    Looks good enough to me, although I haven’t checked the source to see exactly how you did it.


    JJJ
    Keymaster

    @johnjamesjacoby

    As of right now there isn’t a turn key solution. Im doing my best to see where the inclusion is going wrong but haven’t had much time the past few days.


    JJJ
    Keymaster

    @johnjamesjacoby

    What breaks it is the inclusion of the wordpress functions in the bb-config.php file. If you delete that code and visit the admin, it will work just fine.


    JJJ
    Keymaster

    @johnjamesjacoby

    Curious if you’ve tried the steps in my wp2.7 topic? It should essentially be the same as with 2.6.3 and everything works pretty well other than the wp header integration.

    In reply to: Replies order in Alpha

    JJJ
    Keymaster

    @johnjamesjacoby

    I never understand how responses like that work.

    You make it sound like somehow you’ve been inconvenienced by us or by bbPress…

    In reply to: uninstalling 0.9?

    JJJ
    Keymaster

    @johnjamesjacoby

    Looks to me like you failed to upload all of the files correctly.


    JJJ
    Keymaster

    @johnjamesjacoby

    or just because I upload bbpress to directory /bbpress/?

    That is exactly why. :)


    JJJ
    Keymaster

    @johnjamesjacoby

    @lorenzo: I’m not exactly sure if there is a modification to do that or not. It seems like it would be an easy enough process with a plug-in of some kind, but that isn’t the point of integration so unfortunately I have little experience with it. :/


    JJJ
    Keymaster

    @johnjamesjacoby

    @lorenzo: Let me ask a question to clarify. If I understand correctly, it sounds like you want to import your blog posts from WordPress and make them topic posts in bbPress?

    @everyone: I am dedicating this evening to trying to work out where the process is failing. Right now, if you do NOT need to use ANY of the WordPress functions in your bbPress theme, the integration works perfectly. Logging in and out of either/or works perfectly with wp2.7 and bbp1.0a2. If you skip step 5 in my above process, there are no operational issues, only theme integration issues by not being able to use the WordPress functions.

    In reply to: Unable to Login

    JJJ
    Keymaster

    @johnjamesjacoby

    That is why…

    2.6x and .9 series won’t integrate or play nice together…

    You could either go back to the 2.5 series of WordPress, or move up to the 1.0 beta version of bbPress…

    In reply to: Unable to Login

    JJJ
    Keymaster

    @johnjamesjacoby

    Which versions of bbPress and WordPress are you using?


    JJJ
    Keymaster

    @johnjamesjacoby

    I’ve logged into both sides with a test account and still run into this problem. It seems that integrating with WordPress interferes with some capabilities. Like, when viewing a topic logged in as Key Master, I can see the IP addresses of people that post, and I have the link to add that topic to my favorites, but I cannot post a reply, I cannot edit the tags, and I cannot see any other admin functions; all of their capabilities return no value.

    I haven’t given up yet! hah!

    In reply to: User Roles Issue

    JJJ
    Keymaster

    @johnjamesjacoby

    It looks like this has been addressed in the trac, but has yet to be repaired. So there is a ticket open for it, it’s on the radar, but still only a blip.


    JJJ
    Keymaster

    @johnjamesjacoby

    Depending on what version of phpMyAdmin you’re host is running, I find this ability currently under…

    “Operations > Table Options > auto_increment”

    There you can change that value back down to what it should be and cross your fingers! :)

Viewing 25 replies - 2,176 through 2,200 (of 2,213 total)