Skip to:
Content

BuddyPress.org

Opened 8 years ago

Closed 8 years ago

Last modified 5 years ago

#6893 closed defect (bug) (worksforme)

Buddypress Avatar Upload Error

Reported by: christopherwayne's profile christopherwayne Owned by:
Milestone: Priority: normal
Severity: normal Version: 2.4.0
Component: Media Keywords:
Cc:

Description

Hello there! I have a problem with avatars BuddyPress. As I have seen, other users have had the same problem is still unsolved. Button to upload the image takes no action. Nor does the rest of the buttons to take a photo or delete the profile picture. It would be good to revise this problem, please. Thank you!

Hola! Tengo un problema con los avatares de buddypress. Según he visto, otros usuarios han tenido el mismo problema y aún se encuentra sin solución. El botón para subir la imagen no realiza ninguna acción. Tampoco funciona el resto de los botones para tomar una foto o borrar la foto de perfil. Sería bueno que revisaran este problema, por favor. Muchas gracias!

Attachments (1)

Captura de pantalla 2016-02-10 a las 4.48.40 p.m..png (48.4 KB) - added by christopherwayne 8 years ago.

Download all attachments as: .zip

Change History (18)

#1 @christopherwayne
8 years ago

  • Milestone changed from BuddyPress.org to 2.4.4

#2 @boonebgorges
8 years ago

Can you open your JavaScript console to look for any errors?

What theme are you using? It looks like it's inserting some weird markup around the interface (the /*]]*/ stuff).

#3 @christopherwayne
8 years ago

The JavaScrip console:

TypeError: e is null
r/<.getShimContainer()
 plupload.full.min.js:13
s/<.init()
 plupload.full.min.js:14
r/l</<.exec()
 plupload.full.min.js:13
r/<.shimExec()
 plupload.full.min.js:13
r/<.exec()
 plupload.full.min.js:13
c/<.init/<()
 plupload.full.min.js:13
i/<.dispatchEvent/</<()
 plupload.full.min.js:13
i()
 plupload.full.min.js:13
r()
 plupload.full.min.js:13
i/<.dispatchEvent()
 plupload.full.min.js:13
i/<.trigger()
 plupload.full.min.js:13
o/</<()

I´m using the Yoo theme Helios. He had not had problems with Buddypress until now I have always used the same theme.

Last edited 8 years ago by imath (previous) (diff)

#4 @christopherwayne
8 years ago

Any ideas to solve this problem? Other users have reported this problem. https://buddypress.org/support/topic/cant-upload-avatars-and-proflie-covers/
My website is www.artnowgallery.net so you can register and see the problem. Thank you!

#5 @christopherwayne
8 years ago

The JavaScrip console on Chrome:
Uncaught TypeError: Cannot read property 'appendChild' of null

#6 @imath
8 years ago

Hi @christopherwayne

Just like @boonebgorges i'm very amazed by the insertion of weird characters in the layout and by the plupload error.

I don't know yet what is causing this issue since it seems you haven't allowed registration on your site.

As it's working fine on our test drive i imagine it's a possible trouble with your theme or with a plugin.

Could you try to temporarly use any other theme to see if it's relative to "Helios"? If not i think i'd try to deactivate plugins one by one till the problem disappears to find the one that is causing the issue.

#7 @christopherwayne
8 years ago

Hi @imath
Yes, it's a problem with the theme as activating another theme this problem does not happen. The surprising thing is that I have always used this theme, but had not had this problem. I do not understand at what point started this error. The users of my website reported the error. I tried to disable all installed plugins and the problem persists. At the moment I have solved the filter that has been recommended in the topic https://buddypress.org/support/topic/cant-upload-avatars-and-proflie-covers/#post-249761. Thanks !!

#8 @imath
8 years ago

@christopherwayne

yw but "Argh", that was one of my fear :) I saw on the forum post another user had the same trouble with another theme so i was hoping for another reason..

I wonder what's wrong with "enfold" or "helios".. Are they loading their content using Ajax?

#9 @christopherwayne
8 years ago

@imath Helios theme uses a framework for design. I'm not sure, but I think if you use Ajax to load the content. Please, you can sign on my site and I grant administrator permissions to you verify directly. http://www.artnowgallery.net/register/

#10 @imath
8 years ago

  • Keywords reporter-feedback added

mmm i'm sorry but i had no troubles to set my cover image and my avatar on your website with the helios theme ?? As you are using the filter to disable the Avatar UI on front end, i've tested on wp-admin/profile

https://cldup.com/gbzE6M6xqA.png

Then, i've tested a cover image. So if there was a trouble with the avatar UI, it would also fail for the cover image.. And everything works great for me.

https://cldup.com/4WowENXbNQ.png

Could this be another browser issue ?? Just in case, I've used Chrome 48.0.2564.109 (64-bit)...

#11 @christopherwayne
8 years ago

Hello @imath ! I am using a filter in the bp-custom.php to solve the problem temporarily: add_filter ('bp_avatar_is_front_edit' 'return_false');
The problem appears when I turn off this filter. I have no problem with the cover image, only happens with me profile picture.
You want to remove the filter in the bp-custom.php for you to try once again to change the profile picture?
I tested with several browsers (Chrome, Firefox and Safari) and the problem persists.
Thank you!

#12 @imath
8 years ago

i hardly see why it would work for the cover image and not for the avatar on front end. But yes if you want me to test it, please remove the filter!

#13 @christopherwayne
8 years ago

I removed the filter. Please try to upload the profile picture on the front end. Thanks!

#14 @imath
8 years ago

  • Keywords reporter-feedback removed
  • Milestone 2.4.4 deleted
  • Priority changed from highest to normal
  • Resolution set to worksforme
  • Severity changed from major to normal
  • Status changed from new to closed

Ok, on your site we have 2 problems:

1/ W3 Total Cache

https://cldup.com/o9NZcbMUd5.png
If the checkbox *Inline JS minification* is checked in WP Admin > Performance > Minify, this plugin will prepend our Javascript templates with /*<![CDATA[*/ and append it with /*]]>*/ .

https://cldup.com/qWB6ZTfP0h.png
This is causing the avatar UI to fail. So i've disabled this checkbox on your site like illustrated on the screenshot above. Ideally if this plugin could avoid doing the *inline JS mininification* for scripts tag having their type attribute set to "text/html" that would be great :)

Once this setting has been disabled i have:
https://cldup.com/wjFunDOrlR.png

But then the cropping step fails... Because of Lazy Load !

2/ Lazy Load plugin: this plugin is making the cropping step to fail. So i've deactivated it. Unless this plugin gives us a way to tell him don't play here (like a specific class or something) i don't see how to deal with it else than not use it :(
A possible way could be to dequeue the lazy load script if on the change-avatar page..

Once Lazy load is deactivated :
https://cldup.com/tdwaBTIKE1.png

Everything works as expected.

So imho BuddyPress is not responsible for these troubles, as you can see. So i think we can close this ticket. Thanks for your feedback.

#15 @christopherwayne
8 years ago

Thanks for your help @imath. It has been very beneficial and will surely serve someone else who has the same problem. Greetings! :)

#16 @DJPaul
8 years ago

  • Component changed from API - Avatars to Media

#17 @kelwin17
5 years ago

thanks i was searching this post, i got the same issue.. now solved

Note: See TracTickets for help on using tickets.