WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Make page contain archive of posts (3 posts)

  1. filipjakobsen
    Member
    Posted 4 years ago #

    Hello.

    I searched myself tired trying to find a solution to this. I am not very skilled in PHP or WordPress, so I hope someone in here can help? It would be greatly appreciated!

    The problem:

    The short story is: I want to show a uniquely styled archive on a subpage, with the menu-item for that subpage, highlighted.

    The long story: I am using WordPress as a CMS for the website of a television station. Every tv-show has it's own sub-page, with a sub-menu, made with this code: <?php wp_list_pages('title_li=&child_of=83&echo=0' . '</h2>' ); ?>. I have a css-class that is applied to all the non-chosen menu-items, and one that is applied to the one representing the page the user is currently on. You can see it in action here.

    Now, I also have an archive of all the episodes from that category currently on the frontpage.

    The problem is: I want one of the subpages (namely this one) to display that archive - and still have the "arkivet"-menu-item highlighted.

    I tried just pasting theloop from the archive-template to the template used on the "arkivet"-subpage, but it just replaces the list of posts with a list of one item, containing the content from the "arkivet"-page.

    I also tried making the "arkivet"-page a category page, by connecting cat=3 to that page. That did not seem to work either.

    How do I go about doing this? Is it even possible?

    Filip J.

  2. filipjakobsen
    Member
    Posted 4 years ago #

    Put another (simpler) way: I want this archive placed on this subpage, with the highlighted menu-item still highlighted.

  3. filipjakobsen
    Member
    Posted 4 years ago #

    I found a solution:

    Using the plugin "list category posts" and customizing a template for the plugin (in the plugin's "template"-folder)

Topic Closed

This topic has been closed to new replies.

About this Topic