WordPress.org

Ready to get started?Download WordPress

Forums

Frantic
[resolved] Changing Archive/Category Thumbnail size (3 posts)

  1. Brian
    Member
    Posted 1 year ago #

    I would like to change the size of the thumbnails that show up on my category pages. I thought i found some code to change in archives.php but it didn't work. If there is custom CSS that could do that for me, that'd be great.

    Here's a link to the page where the thumbnails are smaller than I'd like.

    Thanks for any help you can offer,
    Brian

  2. WPThemes.co.nz
    Member
    Posted 1 year ago #

    Hi @gophumek, I think you probably changed line of code in archive.php that looked like this:

    $image_img_tag = wp_get_attachment_image( $image->ID, array(100, 85) );

    where you changed 100 and 85?

    There are actually 3 of these that you need to change.. The first one is in line#44 and the code is like in the above.

    The second one is within line# 53 and looks like this:

    ?php the_post_thumbnail( array(100, 85) ); ?>

    and the third one is in line #60 and looks like this:

    $my_image = wp_get_attachment_image( $firstimg->ID, array(100, 85) );

    if you notice all of these have 100 and 85 which correspond to width and height respectively.

    One other thing. If you are doing any modifications to a theme, I highly suggest creating a child theme and doing your modifications from there.

    Here is a good article from WPTuts Plus http://wp.tutsplus.com/tutorials/theme-development/child-themes-basics-and-creating-child-themes-in-wordpress/

    while here is the official article from WordPress Codex:
    http://codex.wordpress.org/Child_Themes

  3. Brian
    Member
    Posted 1 year ago #

    I thought I had done that before, but I think I didn't increase the size large enough to notice a difference.

    Thanks for the help and especially the encouragement to try it again. This time, I tripled the size and it looks great.

    Thanks again so much for your help Charles.

    (RESOLVED) - forgot to check the box (sorry)

Topic Closed

This topic has been closed to new replies.

About this Theme

About this Topic