Skip to:
Content
Pages
Categories
Search
Top
Bottom

Re: Forwarding bbPress logins to WPMU login page.

I’m trying to have a central signon at my site, where users must sign onto WP first and access bbPress via a page link. The logic you’ve provided looks like it can be incorporated to include the bbPress login page, is this correct?

I think kind of — I’m not 100% sure what you’re describing so let me try a different way.

If you force all registration to go through WPMU, then you can use the in-line login form, native to bbPress, to permit users to log in via bbPress, and they will still be logged in on WPMU. That’s the basic plus of integration :) Login on WPMU, you’re in on bbPress, and vice versa.

In my template, make my login-form.php file look like this:

<form class="login" method="post" action="<?php bb_uri('bb-login.php', null, BB_URI_CONTEXT_FORM_ACTION + BB_URI_CONTEXT_BB_USER_FORMS); ?>">
<p>
<label><input name="user_login" type="text" id="quick_user_login" size="20" maxlength="40" value="<?php if (!is_bool($user_login)) echo $user_login; ?>" tabindex="1" /> <?php _e('User Name'); ?></label>
<br /><label><input name="password" type="password" id="quick_password" size="20" maxlength="40" tabindex="2" /> <?php _e('Password'); ?></label>
<br /><input name="re" type="hidden" value="<?php echo $re; ?>" /> <?php wp_referer_field(); ?> <input type="submit" name="Submit" class="submit" value="<?php echo attribute_escape( __('Log In') ); ?>" tabindex="4" /> <label><input name="remember" type="checkbox" id="quick_remember" value="1" tabindex="3"<?php echo $remember_checked; ?> /><?php _e('Remember me'); ?></label>
<br /><a href="http://yourdomain.com/wordpressmu/wp-register.php">Register</a> | <a href="http://yourdomain.com/wordpressmu/wp-login.php?action=lostpassword">Forgot password?</a><br />
</p>
</form>

What this does is, if someone clicks on the registration or forgot password links, is take them right to the WP side. Now from there, it’ll log them back in to the WP main page, IIRC, but the login form itself, being inline, will keep the user on the same page as they logged in from, so they don’t appear to go anywhere.

Does that make sense?

Are there any other backdoors or pages users can directly access from the outside that may need redirection?

Since the bbAdmin pages are locked to admins, I don’t think you need to worry about that.

Skip to toolbar