• Hey Guys,

    I’m trying to setup my core blog page like this. The latest two posts will show the full content along with a full-size image.

    I’d like to have the 3rd, 4th and 5th oldest posts show on a different section of the page, and just display an excerpt of the post, with a smaller/secondary type image. I’m not sure what the best way would be to go about doing this.

    Any suggestions would be appreciated.

    Thanks.

Viewing 3 replies - 1 through 3 (of 3 total)
  • You have to create 2 Loops. Search the Codex for “The Loop”.

    Then, you have to call from inside the loops for two different custom fields, each linking to a different image (full size, thumbnail).

    You can use something like this:
    For the first (full size image):
    <a href="<?php the_permalink() ?>" rel="bookmark"><img src="<?php echo get_post_meta($post->ID, "image", true); ?>" alt="<?php the_title(); ?>" /></a>

    For the second one:
    <a href="<?php the_permalink() ?>" rel="bookmark"><img src="<?php echo get_post_meta($post->ID, "thumbnail", true); ?>" alt="<?php the_title(); ?>" /></a>

    Obviously, you have to define the custom fields in the Write Post panel, using the keys “image” and “thumbnail”.

    Hope this helps!

    Thread Starter kraftomatic

    (@kraftomatic)

    That does .. so I just need to add the code which checks for which post count it is (most recent, 2nd most recent, etc. etc.) it appears ..

    Tom Lany

    (@tomthewebmaster)

    Thanks! This helped me a lot!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘How To Setup Multiple Post Images and Post Order’ is closed to new replies.