WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Where to add function code? (9 posts)

  1. eraleks
    Member
    Posted 2 years ago #

    Hi everyone!

    I've been reading many places about a function ( get_last_updated() ) that in some way makes it possible to have a page on the main blog of the network show all new posts on all the blogs on the network.

    The only problem is: I can't find anywhere that explains where I shall put this code... Any help? And when I finally have added the code to the right place, how do I use it?

    What I'm trying to do is have the front page of the "mother blog" on the network, to show new posts from all other blogs on my network.

    Any help?

  2. You have to place it in a template file, like home.php in your theme.

    You may find it more useful to just use already built widgets that use this function to show the same thing.

    http://wordpress.org/extend/plugins/diamond-multisite-widgets/

  3. eraleks
    Member
    Posted 2 years ago #

    Interesting... I've been searching the net for hours and hours and didn't find that plug-in! Nice, thanks!

    But, it's not spot on what I want. I want all the posts to come up the same way as when you post posts to your own blog. To fill the entire front page. Is this possible?

    Do you have any other tips on good plug-ins?

    I found a plug-in that let users add themselves to blogs after they've registered on the mother-blog, but it didn't work properly. This is something I could really use. Do you have tips for plug-ins etc that can do this sort of things?

  4. But, it's not spot on what I want. I want all the posts to come up the same way as when you post posts to your own blog. To fill the entire front page. Is this possible?

    that function you were looking at earlier wouldn't do what you want either. ;)

    If you want all posts like that, use this:

    http://wordpress.org/extend/plugins/wordpress-mu-sitewide-tags/

    you may want do dig around my archives at http://wpmututorials.com

  5. eraleks
    Member
    Posted 2 years ago #

    Fantastic!
    That plug-in seems to really do the job =) Thanks a lot for your help!

    But if you don't mind a need help with 1 more thing. I'm quite new to wordpress and don't know nothing about coding :/

    On the set-up it says: "Create posts in your main blog. All posts will appear on the front page of your site. Remember to to add a post loop to home.php in the theme directory if it exists."

    How do I add a post loop to home.php? That didn't tell me anything :P

  6. Ignore that part. you do not need to do it. its old instructions based on the assumption you were using an older theme that came by default.

    In other words, your theme likely does not have a home.php, right Then no worries.

  7. eraleks
    Member
    Posted 2 years ago #

    It works!! I love you right now...
    The plug-in created a new site called tags for the blog archive. Is this good or bad? I could also put it in the main blog?

    Thanks so much for invaluable help!

  8. The plug-in created a new site called tags for the blog archive. Is this good or bad?

    that's what it is supposed to do unless you tell it to use the main blog. Your call.

  9. eraleks
    Member
    Posted 2 years ago #

    Strange thing happend here... Suddenly it doesn't work anymore. I've done much with the site since last time though. When I create a new post on some of the sub-blogs, nothing happens on the mainpage :/ Any sugestions?

Topic Closed

This topic has been closed to new replies.

About this Topic