We all know that the AutoMattic guys use their own stuff, but after each site has been skinned with all their CSS magic, sometimes it’s hard to see… I thought we should savour the moment the wordpress.org forums ran with the default bbpress theme
Hi Ateale,
Which script did you use cos the one i found to convert it did not work for me?
thanks.
Well, in this case I am calling the header file from wordpress on the bbpress pages. The only problem is that I have things in the bbpress header like
bb_is_user_logged_in()
and
is_topic()
which create tons of problems when I put that code in the wp header file. I was able to load wp when bbpress loads, but it seems like the opposite would also be useful, to register bbpress when wp loads. I suppose through reverse engineering, I could figure that out on my own?! Otherwise, I would like to just be able to tell the page, “Hey, are you wordpress, then load this…otherwise, don’t load it. And if your BBPress, then load this, otherwise don’t load it”.
Currently I am also trying to specify which stylesheets to load. If it’s wp, I want the wp stylesheet, and if it’s bb, I want the bb stylesheet, and I don’t want the conflicts when both load.
1 – Does this make sense?
B – Is there a solution? and
4 – Am I overlooking a more obvious solution?
Ron
What kind of content are you trying to distinguish between? Theme content or actual content? With wordpress being a blog and bbPress a forum, the content itself would be different. I guess I don’t quite understand exactly what you are trying to do. Could you explain to me like I am 5 years old (my wife says I act that old anyways 
Trent
Ok, I am trying to serve up content based on whether a user is on the WP side of my site, or on the BB side. Trent, you helped me with this earlier, but you helped me find a much more common sense solution to the problem in that situation.
Here’s what I’m wondering: Is there any way to say “if bbpress” then do this, or “if wordpress” then do this? I can’t seem to find the code I need to tell wordpress AND bbpress to both understand and accept this discrimination. Thanks
Ron
It seems goofy to be discussing WP on a bbPress forum, but this is important for theme integration between the 2. Here is my login form in my sidebar (well ex sidebar as I use wordpress.com now). I use a conditional to welcome the user or display the login form.
<li id="login">
<?php
global $user_ID, $user_identity;
get_currentuserinfo();
if (!$user_ID):
?>
<label for="s"><?php _e('Login:'); ?></label>
<ul>
<li>
<form name="loginform" id="loginform" action="<?php echo get_settings('siteurl'); ?>/wp-login.php" method="post">
<div><label><?php _e('Login') ?>:<br /><input type="text" name="log" id="log" value="" size="15" tabindex="7" /></label><br />
<label><?php _e('Password') ?>:<br /> <input type="password" name="pwd" id="pwd" value="" size="15" tabindex="8" /></label><br />
<input type="hidden" name="rememberme" value="forever" />
<input type="submit" name="submit" value="<?php _e('Login'); ?> »" tabindex="9" /><br />
<?php wp_register('', ''); ?>
<input type="hidden" name="redirect_to" value="<?php echo $_SERVER['REQUEST_URI']; ?>"/></div>
</form></li>
<li><script type="text/javascript">slvBanner();</script></li></ul>
<?php
else:
?>
<label for="s">Welcome <?php echo $user_identity; ?>!</label>
<ul>
<?php wp_register(); ?>
<li><a href="<?php echo get_settings('siteurl') . '/wp-login.php?action=logout&redirect_to=' . $_SERVER['REQUEST_URI']; ?>"><?php _e('Logout'); ?></a></li>
</ul>
<?php
endif;
?>
</li>
Trent
It’s better than Christmas…
But really, I have to say that even though I am much more familiar with phpbb, and even though it has a (currently) larger, more active community, and even though there are many more features, I chose to stick with bbpress to integrate with wordpress.
First of all, the integration process, though buggy now, will no doubt only get simpler and cleaner. I also expect to soon see the types of features that I need, and a shortage of the code that I can do without.
In fact, my decision may even have been in part due to the “code is poetry” which is written at the bottom of each page, but more importantly in the code. I’m excited to see the developments, and would even like to get to the point where I can lend a hand to the community like others are.
Thanks again. Hey, since I have you here, maybe I can ask you a quick one…I’m looking for a way to display content solely based on whether it’s a wordpress page or a bbpress page. For instance, I would like to have the login controls for the wordpress site be in the sidebar when wp is loaded, and the bbpress controls there when bb is loaded.
I imagine it wouldn’t matter which way the user logged in, but there are a few things I would like which I haven’t been able to achieve due to the way I have to put absolute path for redirects, etc. Here are the features I need, maybe you can suggest a more elegant solution for them?:
– Login Redirects to last visited page
– Display selective content based on which side the user’s on (bb vs wp)
– I seem to be having some issues with relative paths? (Actually, I think I may have just figured this out, and I may just be dumb)
– Some other thing I’ll ask about in 7 minutes or less, I’m sure…
I’m a beginner, but not a newb. (anymore). I feel I am getting a pretty good grasp, but I still get confused now and again. Thanks for any feedback you can give.
Well, I for one, would absolutely LOVE to see you all do hosted forums… have it intergrated into WordPress, that would be the bomb diggity man…
Anyways, just a thought.
-CHuck
Who knows. Maybe wordpress.com will spark some kind of hosted bbPress solutions. May be wishful thinking though….
Trent
How come ya’ll don’t offer hosted forums?
Like http://invisionfree.com/
I think yours looks 100% better and more than likely easier to config too.
just wonderin’
WordPress is awesome, BTW… could use a more themes… and customizeable Smilies, But other than that it rocks…
and you shant ever hear me complain… *hehe*
-Chuck
Its all css now, I got the php and html done, I have to do a lot of css work to make it look good.
It’s exactly what I did, and a bit outdated. I might have to switch themes.
Typo and it stripped the link. It is working now above as well as here:
http://www.adityanaik.com/blog/bbpress-and-wordpress-integration/
Trent
what article? Theres no link.
I have never tried what you are doing (in terms of this type of integration), but maybe this article by So10 might be something that can help in the meantime? If not, disregard 
Trent
I got it right except for in k2 it looks really weird. Its all over the place. Look at thetechkid.com/bbpress to see whats wrong with it.
Austane, I use k2 and could you share your header and footer info with me?
~andyh2
I seem to be having a similar problem here, but when I add:
require_once('/wp-content/themes/BabyQuestions101/header.php');
in my bb config.php file, I get this error:
Warning: main(/wp-content/themes/BabyQuestions101/header.php) [function.main]: failed to open stream: No such file or directory in path/to/babyquestions101.com/forum/config.php on line 3
Fatal error: main() [function.require]: Failed opening required ‘/wp-content/themes/BabyQuestions101/header.php’ (include_path=’.:/usr/local/lib/php’) in /path/to/babyquestions101.com/forum/config.php on line 3
(the require_once code is just below the php tag, like this:
<?php
require_once('/wp-content/themes/BabyQuestions101/header.php');
// ** MySQL settings ** //
define('BBDB_NAME', '////'); // The name of the database...
I can’t seem to make this error go away.
Also, is it true that with bbpress .75 I now DO NOT need to add the following line to my config.php file?:
define('WP_BB',true);
Any help here would be appreciated.
Not all the servers, just the one that’s in charge of bbPress.org and WordPress.org.
It’s getting hammered after the release of WP 2.1.
We’re getting new servers soon, though, so take heart!
the thing is, i am not using a theme, per say. i have got an index.php file and then have a folder with the worpress installation. i have just followed a tutorial, i have not got a proper theme applied to WP. the tutorial i followed it here. It is a tutorial for an awesome mac-only program called RapidWeaver
okey, I tried that but I cant get it work. I just copied the code you wrote and changed the domain. For the moment I’m testing my forum in my localhost. This is the code I use:
$bb->usercookie = 'wordpressuser';
$bb->passcookie = 'wordpresspass';
$bb->cookiedomain = 'localhost';
$bb->cookiepath = '/';
I can add that I’m a totally newbie to cookies!