Oct
24

Include a Site-Wide Feed in WP MU

Using the WPMU SiteWide Feed plugin by IT Damager, it is possible for you to provide a site-wide feed in your WordPress MU community. This plugin generates three RSS 2.0 feeds comprising of posts, comments, and pages across all blogs on your WPMU powered site.

Using this plugin in WordPress MU not only allows you to provide a site-wide feed, but also gives you some nice configurations in the administration panel, as well. If you, your readers and your users would like to see what is being posted and discussed within your community - this plugin will provide you with a full feed that will do just that.

You can find the documentation for the WPMU SiteWide Feed Plugin here - and the developer has verified that it works with subdirectory AND VHOST (subdomain) installations of WordPress MU.

I recently implemented this plugin on a client project I completed. In their custom WordPress MU theme, I added this code bit to aggregate the site wide feed into their front page:

<?php // Get RSS Feed(s)
include_once(ABSPATH . WPINC . '/rss.php');
$rss = fetch_rss('http://writes-about.com/wpmu-feed/');
$maxitems = 6;
$items = array_slice($rss->items, 0, $maxitems);

?>

<?php if (empty($items)) echo '<ul><li>No items</li></ul>';
else
foreach ( $items as $item ) : ?>
<ul><li><a href='<?php echo $item['link']; ?>' 
title='<?php echo $item['title']; ?>'>
<?php echo $item['title']; ?></a> by <a href='<?php echo $item['link']; ?>'><?php echo $item['dc']['creator']; ?></a></li>
<li class="excerpt"><?php echo $item['description']; ?></li>
<li class="story">&raquo; <a href="<?php echo $item['link']; ?>">Complete Story</a></li></ul>

<?php endforeach; ?>

Pretty nifty!

One Response to “Include a Site-Wide Feed in WP MU”

  1. Arun Raghavan Says:

    The itdamager.com domain seems to have expired — is there any other place to find this plugin?

Leave a Reply »

Close
E-mail It