Support » Developing with WordPress » Thumbnails for Dashboard Posts Page

  • I bought a e-commerce theme from themeforest. The theme is great and very easy to use. The inventory is added via posts. The titles we have decided to use are the inventory numbers. The problem with that is that if you want to edit a post, you have to go and find the inventory number first, since the posts titles are not descriptive enough to know which piece/post it is.
    I would love to have a thumbnail in the wordpress dashboard posts page (not the front-end view) to be able to find the posts faster.
    I was wondering, if there are any plug-ins that can do that. It might have to be coded into the theme. Anybody have any ideas?

Viewing 5 replies - 1 through 5 (of 5 total)
  • If you are using the most recent version 3.1 you will see and ‘edit post’ button in the much loved/much hated admin bar.

    Well, you can add thumbnail support in your theme. Just add this code in functions.php

    if ( function_exists( 'add_theme_support' ) ) {
      add_theme_support( 'post-thumbnails' );
    }
    // THUMBNAILS TO ADMIN POST VIEW
    add_filter('manage_posts_columns', 'posts_columns', 5);
    add_action('manage_posts_custom_column', 'posts_custom_columns', 5, 2);
    
    function posts_columns($defaults){
        $defaults['voodoo_post_thumbs'] = __('Thumbs');
        return $defaults;
    }
    
    function posts_custom_columns( $column_name, $id ){
        if( $column_name != 'voodoo_post_thumbs' )
            return;
        echo get_the_post_thumbnail( $id, 'admin-thumb' );
    }

    Just note down at the bottom where i’ve added the_post_thumbnail for an added image size of admin-thumb, make sure that references some image you have registered of an appropriate size. Giant images will make your post view look nasty.

    Karandash

    (@karandash)

    Where can i see the code, which makes different sizes images? I mean how WP makes image smaller or cut it.

    GRAQ

    (@graq)

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Thumbnails for Dashboard Posts Page’ is closed to new replies.