Featured Image (4 posts)

  1. Mon
    Posted 3 years ago #

    I'm wondering if there are any ways that I can make the featured image bigger and not round. And I don't know what's wrong but when I press a category, the posts appear without featured images. Since mine is a fashion site, it is necessary that the posts appear. Any suggestion will be appreciated. I'm new to wordpress. Thanks.

  2. Caroline Moore
    Theme Author

    Posted 3 years ago #

    Hi there! Yes, you can use CSS and basic WordPress functions in a child theme to do this. I recommend using Firebug for CSS work--makes it much easier.

    You'd want to target the wp-post-image class in your child theme's style.css and set the border-radius property to 0.

    To make the featured images larger, you'll need to create a new functions.php file in your child theme and overwrite set_post_thumbnail_size() with the dimensions you'd prefer. Hook this into after_setup_theme like so:

    child_theme_thumb_size() {
       set_post_thumbnail_size( '150', '150', true ); //change the values to whatever dimensions you want
    add_action( 'after_setup_theme', 'child_theme_thumb_size' );

    To add them to the archive pages, you'd look at the code in index.php for adding the post thumbnail, then copy and paste that code into a new copy of archive.php in your child theme.

    I haven't tested this, so you may need to play around with it a bit to get it to work for you.

  3. Mon
    Posted 3 years ago #

    Thanks. I got the thumbnail sizes. However, I cannot find where you added post thumbnail in index.php since the functions used in index and archive are basically the same
    get_template_part( 'content', get_post_format() );.
    I added the code the_post_thumbnail( 'post-thumbnails' ); before that line so the thumbnails showed but they are too small and out of boundary.
    Can you suggest something about it?

  4. Caroline Moore
    Theme Author

    Posted 3 years ago #

    Ahh, check in content.php, and add the code in a child theme's copy of content.php.

Topic Closed

This topic has been closed to new replies.

About this Theme

About this Topic


No tags yet.