Changing the Thumbnails That Appear in a Gallery

Is there any way to change the way WordPress displays my
thumbnails?
You’re bound to encounter this at some point: Your thumbnails
are too small. Or too big. Or you don’t want them squareshaped.
What to do?
Ordinarily, WordPress creates square thumbnails, measuring
150 pixels wide by 150 pixels tall. If your picture isn’t a perfect
square, WordPress crops off the edges to make it a square.
There are two ways to change the size and shape of your
thumbnails. The first is to edit the shortcode in HTML
view (using the Text tab), and add the size attribute, which can
take one of several values. The default is thumbnail, but your
other choices are medium or large, which tell WordPress to get
medium-sized (300 × 300 pixels) or large-sized (1024 × 1024
pixels) versions of your picture and display them instead. In
both cases, WordPress sizes the picture proportionally, rather
than cropping it into a square.
This raises an excellent question: How does WordPress decide
how big to make your thumbnails in the first place, not to mention
the medium- and large-sized versions of your pictures?
The answer leads to the second way to change your gallery
thumbnails—by changing the settings in the Settings→Media
section of the dashboard. There you see settings that let you
tweak the standard thumbnail size (150 × 150), as well as the
maximum dimensions for medium-size pictures and large
ones. On a self-hosted site, you’ll also find a setting named
“Crop thumbnail to exact dimensions.” Turn off the checkbox
and WordPress proportionally sizes your thumbnails to match
the dimensions of the actual picture, rather than cropping it
into a square (see Figure 10-9).
One caveat applies when you change these settings: WordPress
creates the thumbnails when you upload your pictures, so
the galleries you created so far will continue using the old
thumbnails (unless you re-upload the pictures and re-create
the gallery). If you run a self-hosted WordPress site, you can fix
this problem using the Regenerate Thumbnails plug-in (http://

tinyurl.com/rthumb). Once you install and activate it, you can
create new thumbnails by visiting the media library (choose
Media→Library). Turn on the checkbox next to all the pictures
you want to change, and then choose Regenerate Thumbnails
in the Bulk Action list. Finally, click Apply to re-create the
thumbnails for those pictures.

Advertisements
Changing the Thumbnails That Appear in a Gallery

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s