I’ve been poking around the Codex in hopes of finding out how WP renames image files when you upload them… it’s probably there but I can’t seem to find it.
It seems that if I upload 1 file, like xue.jpg, that I get many files, like:
xue-123×456.jpg
xue-456×789.jpg
and so on. I take it that WP is making a series of different sizes for easy use in resizing or thumbnails or different displays or, haha, IDK really why WP does this, but I assume it’s something like that.
So FIRST QUESTION – why is WP doing this and is there a predictable format to understand what the naming is?
SECOND QUESTION – I’m not certain this is the issue, but it seems that when I try to import a site using WP importer v0.6 that I get a lot of broken links which seem to be related to this naming issue. The post will call for, eg:
xue-456×789.jpg
but the importer didn’t get that file. It DID get
xue.jpg
and if I manually go through the posts and delete the “-456×789” so it’s calling for just “xue.jpg” then the image IS there and it does load. But this isn’t practical for lots of posts.
I’d like to understand better how images are being renamed on upload, and how this does or doesn’t get handled if the blog is later imported to another host.
TY!
1 Answer
Those numeric suffixes are image sizes corresponding to the width/height values in wp-admin->Settings->Media
. It is part of the thumbnail system. If the right image manipulation libraries are installed on the server, WordPress will create these different image sizes when you upload an image. The idea is that you can then load appropriately sized images for different locations and don’t have to load full size images all the time and scale them in the browser, which is not efficient.
I’ve used that importer (assuming you mean this one) and it did pull in those multiple image sizes, so I don’t know what the issue is with that.