How to theme user profile parts added by other modules?
petiar - July 27, 2008 - 18:04
Hi everybody,
I've managed to theme our user profiles, so they now looks nice (http://folk.sk/uzivatel/petiar). I am using this code:
<?php
$uid = arg(1);
$myprofile = user_load(array('uid' => $uid));
?>to put all information into the $myprofile object. So far so good. However, when I install (just an example) User Visits module (http://drupal.org/project/user_visits) I can't see the variables counted by this module in my $myprofile object. That actually means that I can't implement them to our profiles. Does anybody know where could I find these variables? I think that the similar problem will be with modules like Friends or any which add something to original profile page.
Thanks a lot.
Petiar

Can anybody help?
I'd be happy if anybody could help me with this, thanks a lot! :-)
--
Petiar
The biggest slovak folk music magazine proudly uses Drupal
http://folk.sk
May this help you a lot
Instead of writing php code, copy all the .tpl files from user module to your theme directory.
Read instructions in each .tpl to use appropriate user data to be render.
And please let us know if any thing solves your problem. :)
All the best!!
Beautifulmind
Know more
This won't help...
Hi,
thanks for your reply, but this will not help me. I need to do an advanced theming and all fields in the $profile variable are themed already (put in HTML tags). What I need is a variable (or object, array, whatever) which contains raw values so I can theme them as I want.
Thanks!
--
Petiar
The biggest slovak folk music magazine proudly uses Drupal
http://folk.sk
Stuck with similar problem
I´ve encounter a similar problem: When I theme profiles, I cannot get contrib modules (that add stuff to profiles) to appear inside the profile page.