Profile photo is not being saved

I want to ask regarding issue in buddyboss child theme , profile pic is not being saved. It is showing the following error "There was a problem cropping your profile photo." , what might be the reason for this issue and how to resolve it ??

  • Predrag Dubajic
    • Support

    Hey darshan,

    Hope you're doing well today :slight_smile:

    Can you give us some more info about where you're seeing this issue, is it in CoursePress which you have selected for this thread?
    Or perhaps when editing your user info, does it happen in backend or you have front end profile editor?

    Please advise, and it would be great if you can grant support access so we can see this in action.
    To enable support access you can follow this guide here:
    http://premium.wpmudev.org/manuals/wpmu-dev-dashboard-enabling-staff-login/

    Best regards,
    Predrag

  • darshan
    • Site Builder, Child of Zeus

    Hi predrag,

    I am asking regarding buddyboss child theme.

    I am trying to upload photo from frontend.

    In profile option "change profile photo option has been given".

    We moved site from development server to production server . But all the images are being pointed to dev server link address. When I am trying to upload new image , it is showing "Crop Image" after image has been uploaded , when I click on "Crop Image" the following error is being displayed "There was a problem cropping your profile photo."

    Can you please tell me where to update new link address?? so that all profile photos will be visible and users will be able to change their photos if needed.

    As it is in production server , I cannot give you access .

  • Predrag Dubajic
    • Support

    Hi darshan,

    It's possible that the issues are related and caused by old domains still being used in database.

    Here's an SQL query that you can run in your phpMyAdmin in order to replace all mentions of old domain with your new one:

    UPDATE wp_options SET option_value = replace(option_value, 'OLD_DOMAIN', 'NEW_DOMAIN') WHERE option_name = 'home' OR option_name = 'siteurl';
    
    UPDATE wp_posts SET guid = replace(guid, 'OLD_DOMAIN','NEW_DOMAIN');
    
    UPDATE wp_posts SET post_content = replace(post_content, 'OLD_DOMAIN', 'NEW_DOMAIN');
    
    UPDATE wp_postmeta SET meta_value = replace(meta_value,'OLD_DOMAIN','NEW_DOMAIN');

    Replace OLD_DOMAIN and NEW_DOMAIN with respective domain and run the query.

    Note: Make sure that you have full backup of your DB before doing this.

    Let us know if that makes any difference.

    Best regards,
    Predrag

  • darshan
    • Site Builder, Child of Zeus

    Hi predrag,

    I updated db with given queries , but now error is like this "Cannot upload image to wp-content/uploads/avatars/14/avatars/14". Previously stored images location is still pointing to our dev IP.

    In which bubbypress tables should I update "NEW_DOMAIN Link" or can I do it from code??

  • Dimitris
    • Support Star

    Hey there darshan,

    hope you're doing good and don't mind chiming in! :slight_smile:

    Could you please use the famous Better Search Replace plugin
    https://wordpress.org/plugins/better-search-replace/
    to search for instances of old domain once more and replace them with the new domain?

    It also provides a "dry run" option, so you can run the query without making any actual changes but getting the results of found items based on search keys. :wink:

    Let us know how that goes!
    Keep in mind to grab again a backup copy before messing around with DB.

    Warm regards,
    Dimitris

  • darshan
    • Site Builder, Child of Zeus

    Hi Dimitris,

    Thank you so much it helped a lot. Now default image is being displayed.

    But I am not able to save another image . Same error is being displayed "There was a problem cropping your profile photo." I mean to say uploading of image is not being successfull.

  • Predrag Dubajic
    • Support

    Hi Darshan,

    Can you check the permissions of your wp-content/uploads/ folder and its subfolders and try setting them to 755.

    You can find more info about changing permissions in below instruction pages:
    http://www.dummies.com/web-design-development/wordpress/navigation-customization/how-to-change-file-permissions-using-filezilla-on-your-ftp-site/
    http://support.hostgator.com/articles/cpanel/how-to-change-permissions-chmod-of-a-file

    Let us know if it works after that.

    Best regards,
    Predrag

  • darshan
    • Site Builder, Child of Zeus

    Hi Predrag,

    Hope you are doing good,

    777 permissions are given to all folders.
    Uploaded images are being stored in backend but in frontend it is displaying this error
    "Upload Failed! Error was: The uploaded file could not be moved to wp-content/uploads/avatars/51/avatars/51." How to resolve this error?

    But actually the path is 'wp-content/uploads/avatars/51' .

  • Predrag Dubajic
    • Support

    Hi Darshan,

    I'm doing well, thanks for asking, hope all is good with you as well :slight_smile:

    I did some research about that error and it looks like it can be related to PHP Safe Mode, can you try asking your hosting provider if PHP Safe Mode is indeed enabled and if they can disable it so you can see if it works after that?

    Best regards,
    Predrag

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.