WordPress renames my images (6 posts)

  1. karramarro
    Posted 10 years ago #

    Hi all
    Since I uploaded latest WordPress version, I'm having some troubles with the image uploading.

    I use to name my images something like: nate-williams-illustration.gif This kind of naming is good for google image search. But now, every time I upload an image, WordPress renames it as :natewilliamsillustration.gif


    Do you know why ?

    thanks in advance and sorry for the bad english

  2. chiensavant
    Posted 10 years ago #

    What version are you using ?

    You said "latest Worpress version"... That could either be WordPress 1.2.2 “Mingus� or a nightly build of WP.

    Nightlies are prone to bugs since they are beta version.
    Whereas Mingus works like a charm.

  3. karramarro
    Posted 10 years ago #

    It's WordPress 1.2.2.

  4. orcnet
    Posted 10 years ago #

    From my limited knowledge of regex line 89 in upload.php should read:
    $img1_name = preg_replace("/[^a-z0-9-_.]/i", "", strtolower($img1_name));

    Note the addition of the -_ which allows correct renaming. This also appears to fix a problem with thumbnails coming up with the right name but the linked filename being wrong in Steve Ivy's upload.php mod.

    Someone might want to check this doesn't cause other problems though. :)

  5. karramarro
    Posted 10 years ago #

    Thanks a lot orcnet !

  6. Arlo
    Posted 10 years ago #

    I have the same problem in WP 1.5.1; "file-name" becomes "filename". Thanks for the fix.

    WP folks if you're reading this, do you know about this bug?

Topic Closed

This topic has been closed to new replies.

About this Topic


No tags yet.