• I’m trying to style the post format aside only on the front page of my blog. Specifically, I want it to give me a larger thumbnail there. Problem is, that also changes the way aside posts are displayed in tag and category archives — which I don’t want.

    This is what I have in my content.php:

    <?php
    		if ( has_post_format('aside') ) {
    		the_post_thumbnail('large');
    		} else {
    		the_post_thumbnail('medium');
    		}
    		?>

    Adding either && is_front_page() or && is_home() to the first conditional statement, however, doesn’t seem to make a difference. Am I doing something wrong?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Moderator bcworkz

    (@bcworkz)

    Does your theme have a content-aside.php template? Your script belongs there, though you obviously do not need to check the format any more.

    Thread Starter Nick Ottens

    (@ottens)

    Thanks for your reply, bcworkz.

    I tried that, adding a content-aside.php, but it doesn’t make a difference because whether it’s the home page or an archive page, it then pulls in that one for the template and I still end up with an image that’s too big.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Style post format on home only’ is closed to new replies.