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.

Display Latest Blog Articles? (a little tricky)

January 17, 2012 2:56am

Subscribe [1]
  • #1 / Jan 17, 2012 2:56am

    nyc

    66 posts

    Might not be tricky for most but what I’m trying to do is if I have 5 articles on the homepage, I want to display the NEWEST blog article with an image, title, excerpt, and read article link so i might have something like this:

    {exp:channel:entries channel="blog_articles" limit="1" disable="pagination"}
    <h3>{title}</h3>
    <p><div class="imgborder"><br />
    {article_image}<br />
    </div><br />
    {article_excerpt}<br />
    <a href="http://{title_permalink=" class="read_story">Read Article →</a><br />
    {/exp:channel:entries}


    Now what do I add to the code below so it will display articles 2-5:

    <ul>
    {exp:channel:entries channel="blog_articles" limit="4" disable="pagination"}
    <li><a href="{title_permalink=">{title}</li>
    {/exp:channel:entries}
    </ul>

    the 2nd block of code might be done incorrectly since I didnt have time to test it, just tryin to figure out how to display article 1 with an img/excerpt and then 2-5 in the unordered list

  • #2 / Jan 17, 2012 3:52am

    danieljohnbarnes

    151 posts

    You want to look at the offset parameter from the doc - link.

    Offset by 1. To be safe you should be specifying a sorting parameter too.

  • #3 / Jan 18, 2012 1:54am

    nyc

    66 posts

    You want to look at the offset parameter from the doc - link.

    Offset by 1. To be safe you should be specifying a sorting parameter too.

    thank you!

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

ExpressionEngine News!

#eecms, #events, #releases