My WordPress site is recently moved, and later I found the image filenames are changed to this kind of filename:
#U4e09#U661f#U4ee5#U..
They are used to be filename in Chinese. Somehow they are changed to this kind of filename and I don’t really know the reason (besides, I don’t have the old files because I changed server and old files are deleted)
Now these images cannot be loaded in my posts. Is there any method to make it work?
This Perl script might work, but only if your file system uses UTF-8 encoding for file names. Give it a try anyway:
Save this as “fixutf.pl”, change its permissions to
0755
, and then either run it from inside the directory that contains all your files, or pass the path to this directory as a command line argument. Please back your files up first, and be aware that the renaming process will overwrite any files of the same name if they exist in the same directory.