Support

Account

Home Forums Backend Issues (wp-admin) Using Post Object field in Multisite

Solved

Using Post Object field in Multisite

    • krismo

    • November 25, 2013 at 7:10 pm

    hello,

    Is it possible that by using the “Post Object” field retrieve the post from another blog.

    First – I choose Blog.
    Secend – I choose post/page – from selected blog

    I have a current blog and separate blogs for each edition which wants to retrieve post-object from the home page.

    – Current
    – 2013
    – 2012 – get posts-object from Current
    – etc

  • Hi!

    Not as is. The post object only retrieves posts from the current wp_posts table in the database. Each blog in a Multisite get’s their own wp_posts table.

    You could add this code yourself .. I think best practice (without too much hassle) would be to in the field-file check if this is a multisite. If so output another option where when setting upp the field you choose from which blog to fetch posts.

    Thing is that this would not allow you to retrieve posts from multiple blogs in the same post-object field. The issue with retrieving a lot of posts from many different blogs is mainly performance. For each post the code would have to switch over to a different wp_posts table and do another query.

    I think you should have a look at the post indexer plugin from wpmudev: https://premium.wpmudev.org/project/post-indexer/

    • krismo

    • November 26, 2013 at 2:56 am

    Hey, thanks for the replies
    Unfortunately, this plugin does not meet the requirements of all supported the project

    Its not solved:/

    • Thomas

    • September 19, 2014 at 10:12 am

    Maybe my new plugin would help

    http://support.advancedcustomfields.com/forums/topic/multisite-relationship-field/

    • Dusza

    • July 10, 2019 at 9:40 am
    This reply has been marked as private.
Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.

We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Cookie Policy. If you continue to use this site, you consent to our use of cookies.