timthumb php script for image resizing with wordpress

timthumb php script for image resizing with wordpress

wordpress tutorial, timthumb php script for image resizing with wordpress. We all know what is the tumthumb script. mainly the worpdress theme developers used the tumthumb php script for resizing the images.

timthumb php script for image resizing with wordpress

But now we dont need to use the tumthumb script in wordpress theme because wordpress api is supporting the similier functionality in wordpress.

Using the wordpress hook we can specify the thumbnail size.

You can set the post image thumbnail size using wordpress hook.

Just copy paste the following code in to your functions.php file


function custom_thumbnail_size() {
return 128; // or whatever you want
}
add_filter('wp_thumbnail_max_side_length','custom_thumbnail_size');

timthumb php script for image resizing with wordpress
timthumb php script for image resizing with wordpress

Published by

Purab

I am Purab from India, Software development is my profession and teaching is my passion. Programmers blog dedicated to the JAVA, Python, PHP, DevOps and Opensource Frameworks. Purab's Github Repo Youtube Chanel Video Tutorials Connect to on LinkedIn

Leave a Reply

Your email address will not be published.