Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7609769
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T01:15:15+00:00 2026-05-31T01:15:15+00:00

I have recently started work on an existing WordPress site. The theme on the

  • 0

I have recently started work on an existing WordPress site. The theme on the WordPress install uses TimThumb excessively, and it really is unnecessary. WordPress native image sizes should be able to handle the functionality required. However, I am not sure how to replace TimThumb.

There is a post-thumb.php in the theme file that generates the thumbnails. The file is as follows:

if (get_option('solostream_default_thumbs') == 'yes') { $defthumb = get_bloginfo('stylesheet_directory') . '/images/def-thumb.jpg'; } else { $defthumb == 'false'; }

$solostream_img = get_the_image(array(
    'meta_key' => 'thumbnail',
    'size' => 'thumbnail',
    'image_class' => 'thumbnail',
    'default_image' => $defthumb,
    'format' => 'array',
    'image_scan' => true,
    'link_to_post' => false, ));

if ( $solostream_img['url'] && get_option('solostream_show_thumbs') == 'yes' && get_post_meta( $post->ID, 'remove_thumb', true ) != 'Yes' ) { ?> 

    <img class="<?php echo $solostream_img['class']; ?>" src="<?php bloginfo('template_directory'); ?>/scripts/timthumb.php?src=<?php echo $solostream_img['url']; ?>&amp;w=150&amp;h=150&amp;zc=1" alt="<?php the_title(); ?>" title="<?php the_title(); ?>" />

<?php } 

} ?>

I just want to replace this entire function with WordPress’ built in the_post_thumbnail('thumbnail') function.

Is it as simple as replacing

src="<?php bloginfo('template_directory'); ?>/scripts/timthumb.php?src=<?php echo $solostream_img['url']; ?>&amp;w=150&amp;h=150&amp;zc=1"

with something like

src="<?php the_post_thumbnail('thumbnail'); ?>"

Any ideas or a push in the right direction would be appreciated. Thanks for reading.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T01:15:16+00:00Added an answer on May 31, 2026 at 1:15 am

    You can add custom thumbnails and use them within your code.

    First you have to add theme support, set the thumbnail name, set the size, and set the size

    add_theme_support( 'post-thumbnails' ); // this enable thumbnails and stuffs
    add_image_size( 'mini-thumbnail', 60, 60, true );
    add_image_size( 'one-more-size', 300, 260, true );
    

    You can then use this in your code by calling the following:

    <?php while ( have_posts() ) : the_post();
    the_title();
    the_post_thumbnail( 'mini-thumnail' );
    the_excerpt(); ?>
    

    WordPress has a good reference page for this implementation and functions: https://developer.wordpress.org/themes/functionality/featured-images-post-thumbnails/

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've started work recently at a new company and they have an existing application
An application I have recently started work on has to register two dll's, because
I have recently started seeing user agents like Java/1.6.0_14 (and variations) on my site
I've recently started using Gradle and replacing my existing Maven-based projects. I have had
I have recently started work on a large project in .net (C#) and I
I have recently started using automapper and it has work fine for me so
I have recently started applying for .Net jobs. I currently work in a sales
I have just recently started git-tfs bridge and seems to work fine for a
I have recently started work on an application that is already deployed to production.
I have recently started learning Silverlight and can't figure out how make this work.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.