Info
- 69 posts
- 29 voices
- Started 4 years ago by fabtest
- Latest reply from gerikg
- This topic is not resolved
*seamless* wordpress integration
-
- Posted 4 years ago #
<?php get_header(); ?> <?php global $forumpage; $forumpage = TRUE; ?>...should be the other way around:
<?php global $forumpage; $forumpage = TRUE; ?> <?php get_header(); ?>You need to set the $forumpage boolean before you call the header, or you won't be able to use it there.
Alternatively, forget about $forumpage, and use a global boolean such as $bbdb that bbPress uses anyway, as suggested by fel64.
-
- Posted 4 years ago #
I changed all of the tops to:
<?php global $forumpage;
$forumpage = TRUE; ?>
<?php get_header(); ?>
but, I am still not getting any changes to the title.hmm, what else could be wrong?
-Baldwin -
- Posted 4 years ago #
Has anyone else been able to get the titles to work?
Thanks!
-Baldwin -
- Posted 4 years ago #
ok i got my header/footer running smoothly, was anyone aware that bbpress get header is written as get_head is this the same ?
oh yea and I was curious, now that the bb pulls in the header/footer of wp it knocks out the style for the forums, whats the recommended next step ?
-
- Posted 4 years ago #
include the kakumei stylesheet in your template header, or copy the kakumei styles and put them into the stylesheet for your wordpress theme.
-
- Posted 4 years ago #
-
- Posted 4 years ago #
won't that mess up your wordpress theme ?
-
- Posted 4 years ago #
It's a stylesheet, it will not interfere with the styles in your WP theme unless there are name collisions between the class/id's.
-
- Posted 4 years ago #
I tried just copy-pasting my kakumei css to my wordpress css and while the structure of bbpress got back to normal with some minor quirks, it majorly disrupted my header and footer and with it my wordpress as well. How would I work around this, any other way then going through the stylesheets and changing everything so nothing's colliding? I feel that's A LOT of work.
-
- Posted 4 years ago #
Ok, so answered my own question in the last post. Just had to go through everything step by step and see what collides and adjust accordingly. No, however, I need help with something else regarding this! I need to add a link to my forum profile edit to my loginanywhere script. It works at the bbpress site but then I switch over to the blog and it says profile_tab_link is an undefined function. Maybe there's even another way to link to the profile edit? Please help!
-
- Posted 4 years ago #
Ok, solved that as well :D
Now, for my next problem. What do I type so it knows when I'm browsing a forum page? If you look at my site I have highlighted tabs for my different sections. I need the forum tab to be highlighted while in the forum and for the start tab not to be! I use is_home for the start tab
http://www.doublepeace.se/forum
Please help!
-
- Posted 4 years ago #
So, if you now go through the template files for your bbPress installation, you will need to replace all instances of "
<?php bb_get_header(); ?>" with the WordPress command "<?php get_header(); ?>". The same thing goes for the footers, so you change all instances of "<?php bb_get_footer(); ?>" to "<?php get_footer(); ?>".I used a simpler method to achieve the same result. Rather than going through and changing every call to bb_get_header() and bb_get_footer() I simply created a custom header.php and footer.php file.
Then in the header I have only:
<?php get_header(); ?>In the footer I have only:
<?php get_footer(); ?>The benefit of this is you only need 2 custom files, you don't need to search and replace all instances, and if you need to setup global vars for the more advanced WordPress integration techniques you only have to add them once into your custom header.php.
-
- Posted 4 years ago #
kenzor -- That would indeed work the same way and be far easier to do. It remains a mystery to me why I didn't do it that way to begin with. I must have lost my +5 Blessed Boots of Intelligence at some point.
-
- Posted 4 years ago #
Thanks for this tutorials guys, it really helps.
One more thing is not straightforward to me, how to integrate the forum Titles. I tried it like it was written here but it didn't work out.
You can see my integration on http://www.tasty.sk/forum
-
- Posted 4 years ago #
There is a really good tutorial to integrate the WP + BBP seamlessly here.
http://www.adityanaik.com/integratepress-part-i/
It worked great for me and includes a Theme for BBP that integrates all WP functions into BBP and keeps the header and footer in tact... the only problem is that the BBP CSS is totally lost.. I am currently trying to create a Master CSS file that integrates the kakumei CSS in my WP CSS.. but my CSS skills are not exactly up to date... Ill keep you posted on how it goes...
-
- Posted 4 years ago #
After talking with the author of the tutorial I am going to create a separate CSS file that I can import into my WP CSS.. I think this is better because then it can be used as a starting point for others using the Themepress BBP Theme.. I think this should be integrated into the next release of Themepress..
-
- Posted 3 years ago #
I am thouroughly confused on how to do this. Where the heck would I actually start? I don't want to integrate the the databases/cookies/etc., I just want to apply the same look of my header and footer at http://www.atriskstoriesofhope.com/ with http://www.atriskstoriesofhope.com/bbpress...
-
- Posted 3 years ago #
vilimaunula - your site akirakurosawa.info is an quite impressive integration of WP and BBPress. I'm wondering how you managed to integrate your forum and wordpress loops into one, as presented on this page: http://akirakurosawa.info/forums/. You are showing a single chronological list of recent posts and comments across both your WP blog and BBPress forum. Would you mind sharing how you did this? I'm very new to PHP so would not be able to tweak things easily to make this happen.
Thanks!
-
- Posted 3 years ago #
deliciousbass:
The "latest discussions" list at http://akirakurosawa.info/forums/ is compiled without the use of WordPress or bbPress loops. Instead, it makes use of two direct hand-crafted MySQL queries to the database, one to the WordPress tables and the other to the bbPress ones.
Basically, both queries search for all the posts (or comments, in the case of WordPress) written in the past month, then put these posts into various arrays. The arrays are then sorted so that the items are in a reversed chronological order, and finally the resulting list is displayed on the page with only the latest post/comment from each thread/blogpost/page included.
In case it is any help, here is the code that I use -- I wouldn't suggest just copy-pasting it to your site though before reading it through and knowing what you are doing. You may at least need to change the table names. I have added comments to give some idea what is done where.
There most probably is a simpler way to do this, the php code could be streamlined, made more error-resistant, and it could possibly also be done with WordPress/bbPress tags, or it could be turned into a plugin, if someone has the time and the energy.
-
- Posted 3 years ago #
vilimaunula - thanks for the help. i'm going to try to digest what you've done - this is way more complicated that what i've done in the past. but i'll check it out and will let you know how it goes!
-
- Posted 2 years ago #
-
- Posted 2 years ago #
I'm a nebie trying to achieve seamless integration.
I pasted this to the top of the bb-config.
$bb->WP_BB = true;
require_once( '/blog/wp-blog-header.php' );This is the error message I get.
Warning: require_once(/blog/wp-blog-header.php) [function.require-once]: failed to open stream: No such file or directory in /home1/endingho/public_html/blog/forum/bb-config.php on line 3
Fatal error: require_once() [function.require]: Failed opening required '/blog/wp-blog-header.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home1/endingho/public_html/blog/forum/bb-config.php on line 3
I am using a Thesis theme.
Is there hope for me?
-
- Posted 2 years ago #
That is a very clear error message: the system cannot find the file you are trying to include in bbPress. You started the file path with /blog. which is an absolute path, starting at the root /. You will probably have more luck with this:
require_once( '/home1/endingho/public_html/blog/wp-blog-header.php' );The $bb->WP_BB = true; part I am unfamiliar with. But the error is indicating that you have the path wrong.
-
- Posted 2 years ago #
I was able to perform an integration (not db just a seamless design) using Kenzor's method:
...in the header I have only: <?php get_header(); ?> In the footer I have only: <?php get_footer(); ?>However I am not able to login. It takes me to the Add New Topic page without having logged me in.
This is what I added to my bb-config file, apart from it's own db configif (file_exists('../wp-blog-header.php')) require_once('../wp-blog-header.php'); else if (file_exists('../../wp-blog-header.php')) require_once('../../wp-blog-header.php');Any advice greatly appreciated,
alvar -
- Posted 2 years ago #
After reading some more posts on login difficulties, I found that removing
require_once('../wp-blog-header.php');allows me to login. But I need that, to get my header and footer. -
- Posted 2 years ago #
Guys, I have to say I imagined it easier! I mean, a user and cookies integration is ready out of the box, but a graphical integration is not that easy.
Anyway, I didn't really get the solution of Kenzor. The idea behind is quite simple, but I got lost thinking where should the header and footer be. -
- Posted 2 years ago #
Yah, it's pretty disappointing to be honest.
-
- Posted 2 years ago #
For the people who can't login. Here are the steps i have taken to make it work:
**
BBpress Part
**
all php files of bbpress
<?php bb_get_header(); ?>
to
<?php get_header(); ?>and
<?php bb_get_footer(); ?>
to
<?php get_footer(); ?>:: bb-config.php::
add just before the ?> ending tag:define('WP_BB', true);
if ( !defined('DB_NAME') ) {
require_once( dirname(__FILE__) . '/../wp-config.php');
}define('WP_BB', true);
if ( !defined('DB_NAME') ) {
require_once( dirname(__FILE__) . '/../wp-blog-header.php');
}**
WordPress Part
**
::wp-blog-header.php::
at the top add
<?php global $forumpage;
$forumpage = TRUE; ?>This should at least make the login part work and replace the header + footer and in some cases (depanding on your WP-Theme??) some css
http://test2.cell-systems.net/ <- thats the testing site. It;s 01:05 here now and I need to get into my bed. I hope this at least helps a bit as it seems most people who have it working 100% don't want to share??>>
-
- Posted 2 years ago #
http://test2.cell-systems.net/
test setup working almost flawless, 100% valid CSS and XHTML :)
Allot of css work goes into it to make the WP theme and Bb theme to work. I'm not combining both CSS files to make 1 standart css file.
-
- Posted 2 years ago #
Great guide. Will try make a theme for it