Recent Posts – suggestion

I was trying to find a way to query the latest custom post of a subsite and display that post on the main website’s home page.

I’m in the process of modifying this plugin quite a bit but I thought I’d make some suggestions you might want to consider in future versions of this plugin:

1. Ability to select specific blog_id(s). This would be easy to add in.

2. Instead of the basic before and after options, it would be great to use a template file. I needed something a little more creative than

  • title
  • and so a template file would have been great – this is the biggest reason for me totally customizing this plugin.

    These modifications would make it really easy to create unique content boxes that pull from subsites on to the home page that go beyond just a simple list.

    If I get the time to turn my customizations in to something that I can share then I will certainly do that.



    • Arun Basil Lal
      • New Recruit

      Hey Tom,

      Thanks for this.

      Totally agree on the Ability to Select Blog ID’s. Even better, have an include list or exclude list and user can choose what to go for.

      Am not sure of the template part, it might not work with every theme, we always have trouble with other plugins that uses templates.

      I think on a theme by theme basis, its easier to have a page template for your theme and use the shortcode on the theme, right?

      You could use:

      <?php echo do_shortcode('[globalrecentposts]'); ?>

      to include it in the template file. Don’t you think?


    • thoward
      • Site Builder, Child of Zeus

      The problem is when you want an output that isn’t as simple as a list of titles which is basically what we are getting here. What if you wanted to use other data from the table such as date?

      As I’ve gotten further in to my own situation, I’m finding that this still isn’t doing what I need. I’m going to have to do more modification of the code and possibly join some other tables to make it work but that might stretch my coding experience. I want to pull the featured image and some custom fields to the home page as well.

      I like where this is headed and it’s definitely given me a starting point that I didn’t have before. I just need to figure to out how to get it to the rest of what I need :slight_smile:


    Thank NAME, for their help.

    Let NAME know exactly why they deserved these points.

    Gift a custom amount of points.