• Hello, I am in the process of setting up my blog, however I cannot see how I can add thumbnails to my posts, I have added a custom field called “thumbnail” and pointed that to a 160 x 160 pixel image uploaded to wp-content, however it does not show up on my post, nor does it show up on my homepage.

    I am using the Twenty Ten 1.1 theme.

Viewing 8 replies - 1 through 8 (of 8 total)
  • If you upload a image from the image uploader within WordPress, it will automatically allow you to resize the image to 150 x 150. Or if you import it first, and then go to modify it, you can edit the exact size of the image.

    if you wish to use a custom field for a thumbnail, you have to actually call the thumbnail somewhere in the code…..

    <?php echo get_post_meta($post->ID, 'thumbnail', true) ?>

    Thread Starter theseeder

    (@theseeder)

    Hello futurepocket, I deleted the 160px x 160px image and uploaded a 150 x 150px image, however it still didn’t show up, so I guess Rev. Voodoo suggestion is correct.

    I must admit I have been using wordpress for years, however have never set it up myself so I am a bit of a noob, where must I put that code?

    well for my option, you put that code wherever you want the thumbnail in your template.

    However if you are editing the twentyten theme, thats a bad idea. Any changes you make to twentyten WILL be lost eventually. The theme gets replaced on every WP upgrade

    read up on child themes…
    http://codex.wordpress.org/Child_Themes

    Thread Starter theseeder

    (@theseeder)

    Hello I will change the theme soon, my only question is which .php files are the ones I need to edit? There are quite a few index.php files and also the only single.php file there is is in the following directory \wordpress\wp-content\themes\twentyten\

    (obviously I know that the twentyten directory will be unused once I switch themes, however while I am playing with the design I can use the twentyten theme to check things out).

    Would I be right in presuming that the index.php file and the simple.php files that I need to edit are the ones in the twentyten directory?

    yes, you would edit the files of whatever theme is active
    index.php controls main blog view
    single.php is single post view

    but with twentyten, it uses get template part in index.php, and refers to loop.php

    So you would actually edit loop.php

    Also, when you change themes, they may already have thumbnail (featured image) functionality

    twentyten uses featured image to change the headers…. a lot of other themes use it to display a thumbnail

    Thread Starter theseeder

    (@theseeder)

    Thanks, I really do appreciate your help, do you know of a theme which has thumbnails already set up?

    Most of them honestly….. Just take a look through all the free themes on here…..

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Adding Thumbnails to WordPress Blog’ is closed to new replies.