Imagecache Profiles uses the function imagecache_profiles_preprocess_user_picture routine to do its override of template_preprocess_user_picture in the core user module. However, genesis calls function phptemplate_user_picture in its template.php which overrides both the user module and the Imagecache Profiles module. I had to remove that from the template.php file in order to get things working properly.

Comments

Jeff Burnz’s picture

Category: bug » feature
Jeff Burnz’s picture

Status: Active » Postponed

Setting to postponed - I'll review this when I start working on the next version.

michelle’s picture

@jmburnz: For when you get to this... Any theme that uses phptemplate_* to override a theme function that is .tpl based will short circuit the whole theme system, which is likely the problem here. If you need to make changes to it, you should use the preproccess system or provide a custom.tpl file in the theme.

Michelle

dave reid’s picture

Another request to get this fixed. Users of your theme cannot use the Gravatar module since your theme has the final but unnecessary override for user pictures. See #373400: phptemplate_user_picture() is unneccessary.

Jeff Burnz’s picture

See #2, apologies but I am too busy to consider the new version at this stage. I could commit to head shortly but that is unlikely before March 10th, the new version is total make over with RTL and many new theme settings and I want to get it all planned out properly before any new commits.

I'm all up for getting rid of it, if someone can tell me how to test if $picture is empty when the user has not added a user picture. In my tests if User pictures are enabled, it returns not empty, even if the user has not uploaded a picture. Should I use isset?

dave reid’s picture

jmburnz, you don't need to check anything with $picture, you just need to remove the phptemplate_user_picture function from both of your themes. I have actually checked through every single other 6.x theme's source code and your two themes are the only ones that have it, and user pictures work just fine on all the rest of them. :)

Jeff Burnz’s picture

Status: Postponed » Active

I test to see if its empty to set a conditional CSS class in comment.tpl.php - so I do need it to return empty if there is no pic to show.

I have to go over the code again, I can see I have a user-picture.tpl.php override as well with a !empty in there on $picture, that might be the one doing the magic, I cant recall right now, I know I wrote some trickery into the function at one stage that made it work.

Jeff Burnz’s picture

@ #5 & #7, darn it! I'm blabbing in the wrong issue queue, this can be ripped out of Genesis no problem, here I am thinking I'm talking about Pixture Reloaded... sheesh, long day guys... long week actually.

Jeff Burnz’s picture

Status: Active » Fixed

Fixed in 6.x-2.x. Has been removed.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.