Forums

Join
bbPress Support ForumsTroubleshootingWordPress session not registered for bbPress

WordPress session not registered for bbPress

  1. Hi,

    I have integrated WordPress and bbPress. They both share the same table for users. I can login in to a user in the database from both WordPress and bbPress. SO they are correctly sharing the same user table. However, when I login as a user for the blog and then click on the forum then click to post in the forum it asks me to log in. I imagine it has something to do with cookies. I have gone through the docs on integration and the post by _CK_ but nothing has made it work yet.

    Please help me identify the problem. If you want I can post the config files for both WordPress and bbPress.

  2. Here are the config files

    wp-config.php

    <?php
    // ** MySQL settings ** //
    define('DB_NAME', 'idea_orbit');    // The name of the database
    define('DB_USER', 'admin');     // Your MySQL username
    define('DB_PASSWORD', 'Am@nda5haye'); // ...and password
    define('DB_HOST', 'localhost');    // 99% chance you won't need to change this value
    define('DB_CHARSET', 'utf8');
    define('DB_COLLATE', '');
    
    // Change each KEY to a different unique phrase.  You won't have to remember the phrases later,
    // so make them long and complicated.  You can visit http://api.wordpress.org/secret-key/1.1/
    // to get keys generated for you, or just make something up.  Each key should have a different phrase.
    define('AUTH_KEY', '7k67k67k76'); // Change this to a unique phrase.
    define('SECURE_AUTH_KEY', '67k67k76k67k76'); // Change this to a unique phrase.
    define('LOGGED_IN_KEY', '67k76'); // Change this to a unique phrase.
    define('SECRET_KEY', 'thisisone{crazy}sectret9084biugfhKey');
    define('COOKIE_DOMAIN', '');
    define('COOKIEPATH', '/starteconome/');
    
    /* this is what I added for integration with bbpress
    $wp->cookiepath = '/starteconome/';
    $wp->sitecookiepath = '/starteconome/';
    define('SITECOOKIEPATH', '/starteconome/');
    /*End What I added*/
    
    // You can have multiple installations in one database if you give each a unique prefix
    $table_prefix  = 'wp_econome_';   // Only numbers, letters, and underscores please!
    
    // Change this to localize WordPress.  A corresponding MO file for the
    // chosen language must be installed to wp-content/languages.
    // For example, install de.mo to wp-content/languages and set WPLANG to 'de'
    // to enable German language support.
    define ('WPLANG', '');
    
    /* That's all, stop editing! Happy blogging. */
    
    if ( !defined('ABSPATH') )
    	define('ABSPATH', dirname(__FILE__) . '/');
    require_once(ABSPATH . 'wp-settings.php');
    ?>

    bb-config.php

    <?php
    
    // ** MySQL settings ** //
    define('BBDB_NAME', 'idea_orbit');      // The name of the database
    define('BBDB_USER', 'root');     // Your MySQL username
    define('BBDB_PASSWORD', 'L!feisg00d'); // ...and password
    define('BBDB_HOST', '');    // 99% chance you won't need to change these last few
    
    define('BBDB_CHARSET', '');      // If you are *upgrading*, and your old bb-config.php does
    define('BBDB_COLLATE', '');          // not have these two contstants in them, DO NOT define them
                                         // If you are installing for the first time, leave them here
    
    // Change BB_SECRET_KEY to a unique phrase.  You won't have to remember it later,
    // so make it long and complicated.  You can visit https://www.grc.com/passwords.htm
    // to get a phrase generated for you, or just make something up.
    // If you are integrating logins with WordPress, you will need to match the value
    // of the "SECRET_KEY" in the WordPress file wp-config.php
    define('BB_AUTH_KEY', '7k67k67k76'); // Change this to a unique phrase.
    define('BB_SECURE_AUTH_KEY', '67k67k76k67k76'); // Change this to a unique phrase.
    define('BB_LOGGED_IN_KEY', '67k76'); // Change this to a unique phrase.
    define('BB_SECRET_KEY', 'thisisone{crazy}sectret9084biugfhKey'); // Change this to a unique phrase.
    
    // If you are running multiple bbPress installations in a single database,
    // you will probably want to change this.
    $bb_table_prefix = 'bb_'; // Only letters, numbers and underscores please!
    
    // Change this to localize bbPress.  A corresponding MO file for the
    // chosen language must be installed to bb-includes/languages.
    // For example, install de.mo to bb-includes/languages and set BB_LANG to 'de'
    // to enable German language support.
    define('BB_LANG', '');
    
    /* Stop editing */
    
    if ( !defined('BB_PATH') )
    	define('BB_PATH', dirname(__FILE__) . '/' );
    require_once( BB_PATH . 'bb-settings.php' );
    
    ?>
  3. When I view my cookies with Firefox it shows that they are setting the exact same cookie. They both set the cookie under the same site and even the same name. When I log in with bbPress it sets another cookie with the same name as the WordPress cookie. I need help :) thanks!

  4. Try forcing in the // WordPress cookie integration speedup stuff.

  5. What is that?

  6. Go to bb-admin/options-wordpress.php

    Scroll down to Manual bbPress config file settings

    Copy that stuff into your bb-config.php

  7. You must log in to post.