If a user does not have a profile picture, the site's default user picture is not used correctly instead. Patch attached.
| Comment | File | Size | Author |
|---|---|---|---|
| default-picture.txt | 1.81 KB | bjaspan |
If a user does not have a profile picture, the site's default user picture is not used correctly instead. Patch attached.
| Comment | File | Size | Author |
|---|---|---|---|
| default-picture.txt | 1.81 KB | bjaspan |
Comments
Comment #1
omnyx commentedsame here - i can't get my default picture to show when I view the profile page. However, it is being displayed when I'm editing the profile page (under the 'change your profile picture' field)
Will try the patch
Comment #2
solutiondrop commentedHas anyone gotten this patch to work? It doesn't work as far as I can tell. I patched it correctly but there is no change.
Thanks.
Comment #3
reed.richards commentedI tried the patch and it actually resolved another problem I was having with the user_image_default i.e. the smaller image uploaded by the user.
However I get an error with the local module after applying the patch saying
It also messes up my admin theme so the default theme will show in admin mode...
Further on now trying the patch by deleting the user's picture and setting the default picture I get nothing. My intuition was that loading a user object, imagecache_profile would add the paths etc. as extra attributes to the user object.
This module is a bit poorly documented.
Comment #4
reed.richards commentedSo I've spotted the problem on line 48 in the module there's a line like this
Now as I understood it imagecache is supposed to be able to do stuff on the fly but I was wrong, this is how the theme_imagecache function looks like:
Obviously calling this at err while the $imagecache_path get messed up thus the logical error message
So conclusion: Get rid of the theme_imagecache call and replace it with a better theme calling function or just a line which creates the image and returns it.
Further on there seems to be problem when doing an override of the phptemplate_user_profile which doesn't get the phptemplate_user_picture started.
Tomorrow I try to write a patch or at least a copy & paste and try solve the error of the not calling.
Selah.
Comment #5
reed.richards commentedSo fixing the stuff temporarily, in the module between line 46-57 there is
Replace it with
And remember the path to your default image is relative your files directory.
The only problem with this is that the default picture is only one size the size you choose when uploading stuff this can mess up your layout. Would be nice if the module actually did the presets on the default image and then saved it in the right catalogue. With the new imagefield default image thingy I am guessing you can do that just by applying the imagecache preset to the field. So I am seriously thinking about migrating the userpicture to a nodeprofile which will make things easier but remove the image showing in drupal core...
Best would be if this module just would add the imagepath to the user image in the imagefield is behaving with imagecache put on it.
Comment #6
socialnicheguru commentedsubscribing.
Comment #7
v1nce commentedCommitted to dev version.
Comment #8
Anonymous (not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.