Support » Plugins » Different sidebars for each page, or asides

  • I’ve searched a little, and I don’t think I’ve found anything useful enough. So my current setup is a bunch of subpages within a specific page. What I want to do is if you click a subpage, it’ll go there, but it’ll have its own sidebar or asides on the side (for updates or like descriptions of the subpage itself). Are there any plugins or hacks that would basically “get” or “retrieve” a different sidebar or asides for each individual page?

    Thanks in advance!

Viewing 13 replies - 1 through 13 (of 13 total)
  • I don’t know of anything like that. I am afraid you’ll have to do it manually.

    All that stuff that katie1 linked to will work – but if you want a different sidebar for every Page that means having a different sidebarXXX.php for every Page.
    Plus, it would either mean that you have a different template for each of those Pages or a sidebar with 628 if_statements… if you have 628 Pages 🙂

    Goodness, sounds soul destroying… 🙂

    Hm… Darn. What I was thinking was maybe when say, I write a page or something, a plugin would be present as to have another text-box so that I can couple a description of the page (which would appear on the sidebar), and the actual content which would be obviously in the content area. But it sounds like that I’ll have to resort to the first method that katie1 proposed. Thanks moshu and katie1!

    a description of the page (which would appear on the sidebar)

    If I am on a page/Page as a visitor — why would I need a description in the sidebar? being already there?

    Well, I was thinking this description to be say, more like a Rating kinda thing. Like, say I have a movie review or summary in the main content page, but I want to be able to put some ratings on the side (Plot 5/10, Dialogue 9/10…)

    Or, I was also thinking, like implementing respective asides for each page so that I can post miniupdates on the side if a certain page was loaded; updates that would be specific to that page.

    But then again, I feel like I’m asking too much, haha.

    Term1nal,

    I have different sidebars on each of my pages, done the old fashioned way, with a different templates for each page. It works, but it is a pain.

    I don’t know if you ran across it in your search, but a while back I began a thread on the same subject: http://wordpress.org/support/topic/55732

    Things got a little off-topic, but seemed to offer some new ideas.

    Let me know if it helps you. I was never able to get this to work on my site, but it’s probably due to my limited understanding of PHP.

    What I’d really like to know: can I use a similar script so that all of my pages can use a single template, and call supporting sidebar information from other posts or pages for each page?

    I don’t really understand if this is possible or not.

    BTW kdharris’ text file with the complete code is gone, but I’ve posted it at http://www.johnhorneguitar.com/sidebar.txt in case you’d like to check it out.

    best,
    John

    Hey John.

    Actually, I read your thread about this, and yeah, it didn’t really resolve anything. Basically your dilemma is the same as mine. What I think is the problem is that a new element will have to be implemented for each page or post in the DB (database). That might need a major plugin; to store extra information for a topic in regards to the sidebar.

    As you have pointed out, I’m not sure if this is possible currently either.

    I might go and ask one of my friend PHP gurus and see if they have any experience with WP. I don’t want to give you false hope though, if I don’t respond back I’m probably off skinning a forum. Haha, good luck!

    Thanks, Let me know what you find out.

    Well, the problem with that is that it doesn’t display anything on the side bar. But the idea is there.

    I’m assuming that you want to do this on a page where there’s a single post? I was thinking that in the loop you could store the $post_id in a variable, and then use
    get_post_meta($post_id, $key, $single);
    or the_meta()
    in the sidebar to display the custom field.

    I don’t know if that would work or not, and I don’t have time to try it out. But that’s how I would probably approach it.

Viewing 13 replies - 1 through 13 (of 13 total)
  • The topic ‘Different sidebars for each page, or asides’ is closed to new replies.