ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

List by Month then by Entry

February 14, 2011 3:24pm

Subscribe [1]
  • #1 / Feb 14, 2011 3:24pm

    jose riveros

    14 posts

    There must be a simple way to do this, but I may not be seeing it. I want to list entries by Month and then by each entry. I tried the following code:

    {exp:channel:month_links channel="links" limit="6"}
    
    <div class="month">
    
    <h3>{month} {year}</h3>
    
    <p><ul class="group"><br />
    {exp:channel:entries channel="links" status="Open" orderby="date" disable="member_data|pagination"}<br />
    <li><a href="http://{link_url}class=web"><span>{title}</span> {entry_date format="%d"}</a></li><br />
    {/exp:channel:entries}<br />
    </ul></p>
    
    <p></div></p>
    
    <p>{/exp:channel:month_links}

    And I get this:

    Screenshot

    As you can see, each entry is repeated as the month parameter is looped. Is there a way to limit the entries to their relevant month without resorting to manually creating parent/child relationships?

  • #2 / Feb 14, 2011 5:43pm

    Ingmar

    29245 posts

    There must be a simple way to do this, but I may not be seeing it. I want to list entries by Month and then by each entry.

    Do you want to show only one month per page, or group by month, as it were, i.e. show a couple of pages with separate headers for each new month?

  • #3 / Feb 14, 2011 6:44pm

    jose riveros

    14 posts

    I have been searching the forum archives and the wiki, but there doesn’t seem to be an elegant way for me to do what I want.

    I am going to revise the list and use Low’s plugin: Low Yearly Archive and create an Archive page.

    Thanks!

    Thread can be closed.

  • #4 / Feb 15, 2011 6:06am

    Ingmar

    29245 posts

    Unfortunately you didn’t answer my question… that said, happy to see you have a solution. Please post again as needed.

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases