Skip to:
Content
Pages
Categories
Search
Top
Bottom

"next page" link redirects to WordPress login page


  • annejan
    Member

    @annejan

    I installed the latest bbPress version (1.0.2) and integrated in WordPress 2.8.4.

    Everything seems working, but only the footer navigation with the “next page” links don’t work.

    I think it is a conflict between the htaccess files of bbPress and WordPress.

    If I switch Options -MultiViews to Options +MultiViews, the “next pages” work.

    But from that moment the topic page redirects to /topic/17475/page/17475 (the latest number isn’t correct).

    Anyone a solution? Thanks in advance.

Viewing 5 replies - 1 through 5 (of 5 total)

  • Adam Harley
    Member

    @kawauso

    Where have you installed WordPress and bbPress relative to each other, and what actually are your .htaccess settings for WordPress?

    Mine is just:

    # BEGIN WordPress
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    # END WordPress

    which seems to hand over nicely to the forums that are under /forums/ with their own .htaccess file


    annejan
    Member

    @annejan

    I installed bbPress in the root of my website and WordPress is installed in the directory “/w”. Because I use WordPress functions in my bbPress theme I call the wp-blog-header.php in the bb-config.php with the following code:

    if ( !defined('ABSPATH') & !defined('XMLRPC_REQUEST')) {

    define('WP_USE_THEMES', false);

    include_once( '/home/forum/test/html/w/wp-blog-header.php' );

    header("HTTP/1.1 200 OK");

    header("Status: 200 All rosy"); }

    My .htaccess settings for WordPress:

    # BEGIN WordPress

    <IfModule mod_rewrite.c>

    RewriteEngine On

    RewriteBase /w/

    RewriteCond %{REQUEST_FILENAME} !-f

    RewriteCond %{REQUEST_FILENAME} !-d

    RewriteRule . /w/index.php [L]

    </IfModule>

    # END WordPress

    My .htaccess settings for bbPress:

    # BEGIN bbPress

    Options -MultiViews

    <IfModule mod_rewrite.c>

    RewriteEngine On

    RewriteBase /

    RewriteRule ^page/([0-9]+)/?$ /index.php?page= [L,QSA]

    RewriteRule ^forum/([^/]+)/page/([0-9]+)/?$ /forum.php?id=&page= [L,QSA]

    RewriteRule ^forum/([^/]+)/?$ /forum.php?id= [L,QSA]

    RewriteRule ^forum/?$ / [R=302,L,QSA]

    RewriteRule ^topic/([^/]+)/page/([0-9]+)/?$ /topic.php?id=&page= [L,QSA]

    RewriteRule ^topic/([^/]+)/?$ /topic.php?id= [L,QSA]

    RewriteRule ^topic/?$ / [R=302,L,QSA]

    RewriteRule ^tags/([^/]+)/page/([0-9]+)/?$ /tags.php?tag=&page= [L,QSA]

    RewriteRule ^tags/([^/]+)/?$ /tags.php?tag= [L,QSA]

    RewriteRule ^tags/?$ /tags.php [L,QSA]

    RewriteRule ^profile/([^/]+)/page/([0-9]+)/?$ /profile.php?id=&page= [L,QSA]

    RewriteRule ^profile/([^/]+)/([^/]+)/?$ /profile.php?id=&tab= [L,QSA]

    RewriteRule ^profile/([^/]+)/([^/]+)/page/([0-9]+)/?$ /profile.php?id=&tab=&page= [L,QSA]

    RewriteRule ^profile/([^/]+)/?$ /profile.php?id= [L,QSA]

    RewriteRule ^profile/?$ /profile.php [L,QSA]

    RewriteRule ^view/([^/]+)/page/([0-9]+)/?$ /view.php?view=&page= [L,QSA]

    RewriteRule ^view/([^/]+)/?$ /view.php?view= [L,QSA]

    RewriteRule ^rss/?$ /rss.php [L,QSA]

    RewriteRule ^rss/topics/?$ /rss.php?topics=1 [L,QSA]

    RewriteRule ^rss/forum/([^/]+)/?$ /rss.php?forum= [L,QSA]

    RewriteRule ^rss/forum/([^/]+)/topics/?$ /rss.php?forum=&topics=1 [L,QSA]

    RewriteRule ^rss/topic/([^/]+)/?$ /rss.php?topic= [L,QSA]

    RewriteRule ^rss/tags/([^/]+)/?$ /rss.php?tag= [L,QSA]

    RewriteRule ^rss/tags/([^/]+)/topics/?$ /rss.php?tag=&topics=1 [L,QSA]

    RewriteRule ^rss/profile/([^/]+)/?$ /rss.php?profile= [L,QSA]

    RewriteRule ^rss/view/([^/]+)/?$ /rss.php?view= [L,QSA]

    RewriteCond %{REQUEST_FILENAME} !-f

    RewriteCond %{REQUEST_FILENAME} !-d

    RewriteRule ^.*$ /index.php [L]

    </IfModule>

    # END bbPress

    I hope you can help me. Thanks!!


    Mark Waterous
    Member

    @delayedinsanity

    Just out of curiousity, why are you sending headers from your bb-config? bbPress/Wordpress will handle this all on their own.

    You also shouldn’t call the blog-header, it causes other problems you can read about around the forums. You should be calling wp-load.php and the following should be more than adequate for your bb-config;

    define('WP_BB', TRUE);
    if (! defined('DB_NAME'))
    require_once(dirname(__FILE__) . '/w/wp-load.php');

    $bb->wp_table_prefix = 'wp_'; // your wordpress db prefix is
    $bb->wp_home = 'http://domain.tld';
    $bb->wp_siteurl = 'http://domain.tld';

    I don’t think this will solve your next page problem, as it looks like they’re being sent wrong from bbPress for whatever reason, but it will avoid a plethora of other problems before they become apparent.

    Thanks for your reply. I copied your code and deleted my own code.

    The WP things in my bbPress are still working, but the “next page” problem is there still too.

    Anyone a solution for the “next page” problem?

    Thanks in advance!!

    I fixed it! :)

    It was the WP-o-Matic plugin…

Viewing 5 replies - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.