• Hi all
    I’m just starting to build a very large information website and I need some help with the navigation and posts. I have installed WP3.7.1 and using twentytwelve theme. I have 10+ years web/HTML/PHP development. This is my 2nd WP website.

    My new website will have over 1000 “pages” (each “post” being shown as a separate page). A website with a similar structure is http://www.southernelectric.org.uk
    Look at the top (horizontal) navigation – hold the mouse over News and you see a drop-down. I have created similar for my site so we have:
    News
    – North
    – South
    – East
    – West
    These are all done as Pages with News as the Parent. This is fine.

    I now want to add news Posts – a Post appears in the aside as Recent Posts (which is good). However, I want to add these Posts to North or South so that when you visit North, the aside shows only the Recent Posts within North, and when you visit South, the aside shows only the Recent Posts within South.

    The aside shows ALL Recent Posts regardless of which page you view. I want each Page to use it’s own aside with it’s own Recent Posts

    Is there any way to customise WP to do what I want? Can I assign a Post to a Parent Page? Do I need a plugin for this? Or do I need to hack the PHP?

    I don’t want to add each news post as a page as this will then appear in the top (horizontal) navigation.

    Any help and advice will be much appreciated!

Viewing 7 replies - 1 through 7 (of 7 total)
  • I’m not able to give you exact advice but it sounds like you probably know enough to figure it out on wordpress.org. They have different ways to create custom pages, including every single page showing something different or unique, or pages that also include posts in this category or that category as well. I’d start here: and then move on to: .

    In the meantime hopefully someone else will come along with better advice!

    if your ‘1000 pages’ are 1000 ‘posts’ (in WP lingo):
    1. add categories called north, south, etc
    2. link each of your posts to relevant category
    3. link category URL to menu
    4. use get_posts loop and use category param to filter results
    ref: http://codex.wordpress.org/Function_Reference/get_posts

    if pages:
    1. make other pages child of north, south, etc parent pages
    2. use get_pages loop. again, use parent param.
    ref: http://codex.wordpress.org/Function_Reference/get_pages

    Make sure that you are using a child theme – otherwise your changes to theme files will be overwritten when WP is updated –

    http://codex.wordpress.org/Child_Themes

    Thread Starter Lordofeverything

    (@lordofeverything)

    thanks guys

    i’ve got the categories set up – the posts are linked to the categories
    what do you mean by “3. link category URL to menu” ?? i can’t see any way to do that ..

    Category items can be added to a custom menu –

    http://codex.wordpress.org/WordPress_Menu_User_Guide

    http://codex.wordpress.org/Appearance_Menus_Screen#Categories

    Do you have a child theme set up?

    Thread Starter Lordofeverything

    (@lordofeverything)

    I haven’t set up a child theme yet – not had time to read all the docs and find my way around the code (I don’t have much spare time to do this at the moment)

    I’ve put the category in the menu now, but isn’t right. Clicking that link in the menu then shows all posts in that category – and the aside is still showing all posts from all categories. I want it to show an introduction to that section and nothing else, with the aside showing links to all posts in that category

    Is there an advantage to using the category in the menu rather than using the page in the menu? Will using the category in the menu make it easier for the aside to list only those posts in that category?

    I’ll look at the get_posts soon …

    O.K. Your setup still sounds confusing but if you look at this site: StrongerwithJenG – the solution might be what you are looking for.

    So “Getting Started!” is a page and set to be the static home page.

    “Inspiration” is a category and shows the most recent posts in the that category like the loop does.

    “Recipes” is also a category but in the menu all the sub items in the drop down menu are pages. Same with the category “Workouts.”

    “Tips” is a page with sub pages.

    I can’t say that is necessarily the best solution but it was the one she felt most comfortable with and she is happy with how it looked. She has the menu created under Appearances -> menus.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Navigation / posts / aside / categories etc’ is closed to new replies.