Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter gh0zt

    (@gh0zt)

    Found a way to fix it but I don’t know how to quickly regenerate all the existing thumbnails. Does anyone know a quick way to regenerate all the thumbnails after fixing the php script below?

    1. Locate this file
    /wp-content/plugins/buddypress/bp-core/bp-core-avatars.php

    2. Locate this code in the file

    // Set the full and thumb filenames
    $full_filename = wp_hash( $original_file . time() ) . ‘-bpfull.jpg’;
    $thumb_filename = wp_hash( $original_file . time() ) . ‘-bpthumb.jpg’;

    3. Change the code to:

    // Set the full and thumb filenames
    $full_filename = wp_hash( $original_file . time() ) . ‘-bpfull.png’;
    $thumb_filename = wp_hash( $original_file . time() ) . ‘-bpthumb.png’;

    4. Uploading a new avatar and cropping it will now create a .png version, the images will now work properly in IE8/9

    5. How can I recreate all the existing thumbnails quickly?

    Thread Starter gh0zt

    (@gh0zt)

    I fixed it by running the script below from:

    /wp-content/uploads/group-avatars

    find . -type f -name ‘*.jpg’ -print0 | while IFS= read -r -d ” f; do
    mv — “$f” “${f%.jpg}.png”
    done

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘[Plugin: BuddyPress] Serious Problem With Images’ is closed to new replies.