Fix For BuddyPress Activity Stream Not Showing Up on HomePage

WordPress 3.0 is here! I know you guys probably know that already. I haven’t upgraded most of my blogs yet just because I don’t want to screw up anything.

(If you are upgrading, you would want to make your Theme WP 3.0 compatible, right? Here is what you would need.)

BuddyPress - SocNet with WordPressBut today morning I just tried upgrading one of my BuddyPress installations since a plugin that I was trying out works only with WordPress 3.0. Back-ed up the database (you should too!), checked if the backup was working and did the automatic upgrade. Everything went smooth, I checked the homepage and boom! It reported a 404.

First idea on my mind was to roll back to WordPress 3.0. So I googled for some WordPress downgrading plugins. Fortunately or Unfortunately there are none. Any plugin developers reading this? You might want to make the First WordPress Downgrade Plugin.

Heck, I can code, I understand WordPress, why not fix the issue? And here it is, the work around.

Create a BuddyPress Page Template for the Activity Stream

You can create a BuddyPress page template on the theme just like we do it for WordPress. Here is an example of how to create and use a WordPress page template. Do the same, but with the code for the Activity Stream page. In the default theme the code for Activity Steam can be found under bp-default/activity/index.php.

Copy that code into the new page template. If you are using the default WordPress theme, here is the page template I created. Just upload this to the bp-default/ theme folder and use it.

Create a Activty Stream Page

Make sure the template is in the root folder. Create a new page. Name in Activity (name doesn’t matter). From the right sidebar of the new page editor, under Page Attributes, choose template as “Activity Page”.

Select Activity Stream in Editor

Publish the page.

Make the Activity Stream as Front Page

Go to Settings > Reading Settings. Choose a Static Page to show on the front page and choose the page that we just created. (I named it Activity, so its listed there as Activity).

Set Activity Stream as Front Page

If everything was all right we would just have to choose the Activity Stream that you can see there.

Remove the Activity Page Listing from the Header Navbar.

Depending on your theme, your Navigation Menu would list pages or maybe not. The default theme lists pages, and the Activity Page we just created would be listed there as well. We don’t need that, right?

Open up header.php and you will see

<?php wp_list_pages( 'title_li=&depth=1' . bp_dtheme_page_on_front() ); ?>

Normally, adding en exclude (&exclude=10,73) parameter to wp_list_pages would work, but for some reason it didn’t work for me. I think its because that page is used as the front page. The exclude was working for other pages like the contact page etc. So I decided to hard code the pages (I only had two thankfully).


<li<?php if ( bp_is_page( 'about' ) ) : ?> class="selected"<?php endif; ?>>
<a href="http://ebtimes.org/about/" title="About">About</a>
</li>

Edit the above code as per your requirement and replace the wp_list_pages in header.php or use an exclude page plugin.

That’s it. Hopefully WP team would fix the issue soon. If you enjoyed the tutorial or need any clarification, let me know.

Email this to someoneTweet about this on TwitterShare on FacebookDigg thisPin on PinterestShare on Google+

Million Clues! is a blog on WordPress, Blogging Tips and the Web. It also covers Reviews on Softwares, Websites and Tools. - http://www.millionclues.com/about/

Posted in WordPress Tagged with: , , ,

12 Comments.

  1. Lots of issues over WordPress 3.0. But I was lucky, didn’t get any problem with theme or plugins.

    And am not into BuddyPress yet, but will soon try it.. thanks for the fix! :)

  2. Vincent says:

    Thanks for your help! This worked great! btw do you know how i can remove the 2 scroll bars above the comments on this page? I would also like to change the order of the posts, With my admin welcome message at the top. Any ideas? Thanks again for your help!

  3. John says:

    Hey all! This is fixed in the 1.2 branch of code and will be fixed in 1.2.5 due out in a few days.

    This is a great way not only to fix the current problem, but also to make really slick custom BuddyPress pages and arrangements that don’t look and feel so BuddyPressy.

    Good work!

  4. Thanks. It works fine with me actually without any effort other than uploading the page. :)

  5. Manesh says:

    Thanks for the post.

    It will be a problem for people with designed blogs to transfer to wordpress 3. All the scripts and pluggins they added have to be compatible with the new version. More over the number of browers also increasing.

  6. Carlisle Holm says:

    This was exactly what I was looking, worked perfect!

  7. Chris says:

    Thanks a bunch!!! I thought I was going to have to start over after I upgraded to 3.0 and everything died. You’re a life saver!

  8. Bali web photograph says:

    thanks brother. . .
    can you visit http://www.jazzphotograph.com?

  9. Mike Kennedy says:

    BuddyPress 1.5.1 is out now! :D

1 Pings / Trackbacks.

  1. Wordpress 3.0 – Mark Waters says:

    […] Stream page creates a 404 , used this workaround for […]

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>