• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer
WPArena

WPArena

WPArena is a premium online resource site of WordPress and is focused on providing excellent WordPress Tutorials, Guides, Tips, and Collections.

  • News
    • Opinion
  • Tutorials
  • Reviews
    • Themes
    • Plugins
  • Comparisons
  • Collections
    • Education Themes
    • Genesis Child Themes
    • Best Responsive Themes
    • Medical WordPress Themes
    • Finance & Business Themes
    • Crowdfunding Themes
  • Resources
    • Inspiration
  • Services
WPArena » Tutorials
Tutorials

How to Get Posts from all Blogs in Multisite Network

Avatar of Noor Mustafa Raza Noor Mustafa Raza Updated: February 20, 2023

FacebookTweetPinLinkedInEmailPrint

Now you can run multiple blogs from one installation of WordPress. This new feature is called Network or Multisite option in WordPress. All you have to do is open your wp-config.php file located in your WordPress root folder. Then add the following line anywhere in the file:

define('WP_ALLOW_MULTISITE', true);

Find more detail on ” How to enable Multi-Site feature in WordPress.” After doing this, you are able to access the network page from Tools » Network. By default, you are allowed to run other blogs as a subdomain. You can use other domains for blogs by using a Domain Mapping plugin (Detail: How to do Domain Mapping in WordPress Multisite Network).

After converting your WordPress single installation into Multisite Network,  you can do some cool things with it. I will see how to get posts from all blogs in the network.

What if you want to get some recent posts from the last updated blogs, not just one? Then get_last_updated() is the function that will save your life!

See a simple example that shows the last post from the last updated blogs:

$blogs = get_last_updated();
echo '
<h1>Last posts in network</h1>
';
foreach ($blogs AS $blog) {
	echo "
<h2>".$blog["domain"].$blog["path"]."</h2>
";
	switch_to_blog($blog["blog_id"]);
		$lastposts = get_posts('numberposts=1');
		foreach($lastposts as $post) :
			setup_postdata($post);
			the_title();
		endforeach;
	restore_current_blog();
}

Reference:

You can read more about WordPress Multisite Network:

  • Best BuddyPress Themes for Social Networking
  • How to manage plugins in WordPress Multisite Network
  • WPMU Functions/get last updated
  • http://codex.wordpress.org/Category:WPMU_Functions
  • http://codex.wordpress.org/Function_Reference#Multisite_functions

You can use these WordPress themes for your Multi-Site Network because they support BuddyPress and BBPress.

ReviewIt – Community WordPress Theme

ReviewIt-WordPress Theme

ReviewIt provides you with a powerful review and community theme that is also 100% BuddyPress compatible!

Key Features

  • 2 Unique Skins – Dark and Light
  • Custom Post Types – Reviews and Slides
  • Powerful Review System – Utilizes GD Star Rating WordPress plugin (requires PHP 5 )
  • Easily Change Tags – Switch the site from movies to games, apps or whatever you want
  • Multiple Review Displays – Display reviews in lists by score, date, based on similarity to other reviews, etc.
  • Total BuddyPress Support – This theme supports BuddyPress but works just fine without it

Live Preview | Detail

DynamiX – Premium WordPress Theme

Theme features:

  • Dual Skin Mode
    – Inner (Main body content) & Outer (Header / Footer area) Skin can be selected
    – Select Skins for the entire website and per page
    – Select from 20 Outer Skins and 2 Inner Skins
  • Non-Post Gallery Slide Manager (Manage all your Gallery Images/Videos in one area)
  • BuddyPress Theme (BBPress Support)

Live Preview | More Detail

TheAllure – Elegant Corporate and Portfolio Theme

TheAllure-wpTheme

TheAllure is a professional and flexible WordPress theme packed with amazing functionality and a very impressive Design. The Theme has Unlimited color choices. It is packed with lots of shortcodes and a powerful admin panel (PowerPanel) that lets you control every aspect of your website.
The Allure theme is very easy to set up, no matter if you are a WordPress beginner or a WordPress pro.
It is also compatible with WordPress MU (Multisite/wp_mu). It is WPML Translation ready and for your convenience, already includes 19 languages for the front end.
Key Features

  • Advanced Admin Panel packed with Options with over 20 sections to help you control every aspect of your website (SelectedTheme’s PowerPanel)
  • Unlimited Colors
  • WPML and Translation Ready
  • 19 Languages Available
  • Cufon Font Replacement with over 25 fonts
  • Custom Post Types: Portfolio Items, Slider Items
  • Supports Custom Menus
  • 3 Sliders: Nivo Slider, Thumbnail Slider, Full Content Slider
  • Fully Flexible Homepage Layout
  • 50+ shortcodes
  • WordPress Multisite (WordPress_MU) Support

More Detail

This post was orginally published on: May 16, 2011 and was updated on: February 20, 2023.
FacebookTweetPinLinkedInEmailPrint

Related Stories

  • How To Add Threaded Or Nested Comments To WordPress

    How To Add Threaded Or Nested Comments To WordPress

  • Why WordPress Categories Are Not Showing

    Why WordPress Categories Are Not Showing

  • How to Managing Your WordPress Multi Sites

Avatar of Noor Mustafa Raza

Noor Mustafa Raza

Ex-Editor in chief

I am a WordPress Developer and Designer, author @WPArena. I am providing Free WordPress consultation and can help you to install WordPress in a secure way to small businesses and bloggers.

Reader Interactions

Join the Discussion
  1. Avatar of AndersonAnderson says

    July 14, 2014

    Dont work with post_type? ‘post_type=property&numberposts=1’

    Reply
  2. Avatar of RahulETSRahulETS says

    September 27, 2019

    Yeah all of these themes are very useful in wordpress I also like this additional feature and thanks for sharing this information with us.

    Reply
  3. Avatar of maztakmaztak says

    November 15, 2022

    It works fine!! Lovely thanks!

    Reply

Share Your Thoughts Cancel reply

Before submitting your comment, we kindly ask that you read our comment policy. Your email address will remain confidential and will not be published or shared anywhere. If you subscribe, you will receive notifications regarding new comments.

Primary Sidebar

Create Custom Logo

Create a Custom Logo with Wix Logo Maker in 6 Steps

How To Change Number Of Posts On Blog Page

Recent Topics

  • 27 Top SEO Companies in the World
  • 12 Ways To Monetize Your WordPress Blog
  • Comparing the Best Employee Engagement Software in the Market
  • Stellar Converter for OST Review: Best Tool for OST to PST Conversion
  • How To Use WordPress as an eCommerce Store

Footer

Top

  • Services
  • Our Themes
  • Facebook
  • Twitter
  • Linkedin

Reviews

  • Beaver Builder Review
  • Beaver Themer Review
  • WP User Frontend Pro
  • Ninja Forms Review
  • MemberPress Review

More Reviews »

Resources

  • Best WordPress Plugins
  • WordPress Permalinks Structure
  • Email Management System
  • Envato Free Files
  • Advertise
  • Write for us
  • Disclosure
  • Terms
  • Privacy
  • Contact

Copyright © 2023 · All Rights Reserved · WPArena is a Project of TechAbout LLC.
We are not affiliated with Automattic or WordPress.

  • Advertise
  • Write for us
  • Disclosure
  • Terms
  • Privacy
  • Contact
Share this ArticleLike this article? Email it to a friend!

Email sent!