View Full Version : Member Profile in UserCP Home
evenmonkeys
04-09-2006, 10:00 PM
Description
I remember seeing this requested a long time ago, and I have been working on it since. This is one of the more complicating modifications that I've done, so I also wanted to put some time into it. Six months may be a bit more time than I wanted, but it was a great learning experience.
Basically, what this modification does is add your own member profile to your UserCP home. Before editing your signature, or before editing your avatar/profile picture, you can see it to determine if it needs to be edited. Of course, your UserCP home will still display your PMs and subscriptions; however, they will be displayed under your profile information.
This being your own profile, I have removed several if statements and certain information areas as you do not need them. For instance, I removed the timestamp and location as it would just tell you you were in your UserCP. Pointless? I think so.
Known Issues
There are two things not entirely working though, and I will gladly take suggestions on how to make it work. Those two things are the profile picture and avatar. The avatar does show and update properly; however, if you do not have an avatar at all, it shows a red x. The profile picture does not update at all, but it will show the first one you ever used. So two things I need to tweak. I've left the avatar open, but the profile picture is currently out right now.
Products to Import: 1
Templates to edit: 0
Files to Upload: 0
Installation Instructions
1. AdminCP > Plugin System > Manage Products > Add/Import Products
2. Click install.
Comments
If you have any questions or comments, don't be afraid to ask. =D I will support this to the best of my ability.
Release Notes
04.09.06 - Fixed a query problem. New product should fix the referral query.
04.09.06 - Initial release.
Support will only be given to those who click install.
This does not include questions before installing.
evenmonkeys
04-09-2006, 10:28 PM
Reserved.
Andrew K
04-09-2006, 10:32 PM
Installed!
Looks and works great.
Daniel
04-09-2006, 10:53 PM
Nice idea. :)
wizardan
04-09-2006, 11:04 PM
Mmmm...
Any idea why I may be getting this message instead of access to User CP?
Database error in vBulletin 3.5.4:
Invalid SQL:
SELECT COUNT(*) AS count FROM sobejoh9_ user WHERE referrerid = 1;
MySQL Error : Table 'sobejoh9_vBforums.sobejoh9_' doesn't exist
Error Number : 1146
Date : Sunday, April 9th 2006 @ 08:02:43 PM
wizardan
04-09-2006, 11:10 PM
Uninstalled the product, and all is fine.
I'm running several hacks, and have a highly stylized skin.
Might be a conflict in code somewhere.
I really like the look of this though, and will follow this thread.
I'll also install it on my test board and then add hacks to see if I can find a problem.
evenmonkeys
04-09-2006, 11:21 PM
I think the problem may have been from an un-needed space I had in the query. I've updated the product and you may feel free to re-try. If that's not the problem, I'll continue to look into it.
yinyang
04-09-2006, 11:26 PM
*installed*
this is a great idea and probably should be standard on vB. However, not all the information is being pulled up, especially all the custom stuff that you can see when you click on a members name from the member list.
in other words, is it possible to make this view identical to the one you would see if you were to access your profile off the memberslist?
evenmonkeys
04-09-2006, 11:32 PM
As of now, this includes the default member profile information. It should be including all custom fields and things like that though. Later down the road, I might be able to make it just include the actual template, but for now... I've reached my limit. Haha. If there is something default that should be showing up... but isn't, let me know.
Snake
04-10-2006, 10:12 AM
Awesome! Just awesome! I've installed this hack and seems to work fine!
Thank you very much, Yarub! I really like it! :)
wizardan
04-10-2006, 11:18 AM
I think the problem may have been from an un-needed space I had in the query. I've updated the product and you may feel free to re-try. If that's not the problem, I'll continue to look into it.
Re-installed.
Flawless.
Thank you:)
rareclownfish
04-10-2006, 08:06 PM
Installed. nice work
trackpads
04-10-2006, 10:33 PM
Excellent!
ShadowOne
04-11-2006, 01:15 AM
does this add any templates? USERCP_PLUS?
ShadowOne
04-11-2006, 01:37 AM
what about adding this code in the plugin...
if ($vbulletin->userinfo['userid'] > 0 && $vbulletin->userinfo['userid'] != '' || !$vbulletin->userinfo['userid'])
{
require_once(DIR . '/includes/functions_user.php');
$vbulletin->userinfo['avatar_build'] = fetch_avatar_url($vbulletin->userinfo['userid']);
if (empty($vbulletin->userinfo['avatar_build']) || !is_array($vbulletin->userinfo['avatar_build']))
{
$vbulletin->userinfo['avatar_build'] = array('noavatar.gif');
}
$vbulletin->userinfo['avatar_build'] = '<img src="' . $vbulletin->userinfo['avatar_build'][0] . '"'.iif($vbulletin->userinfo['avatar_build'][1],$vbulletin->userinfo['avatar_build'][1],'').'border="0" alt="Edit Your Avatar" />';
Then just make a noavatar image...and turn this into an extension...
hotwheels
04-11-2006, 07:28 AM
very nice addition.......
hotwheels
04-11-2006, 07:31 AM
Dang, that is really neat............thanks alot for your hard work on this one
evenmonkeys
04-11-2006, 06:13 PM
does this add any templates? USERCP_PLUS?
Yes, this product creates a new template. As of now, this modification overwrites your current USERCP template via plugin with USERCP_PLUS. I did it this way because there are very few, if any, modifications that touch your USERCP template, and it allowed me to make the additions I needed. However, I do plan on changing it to just adding a variable to the top to call for the additional html. As of now, that's a level over my head. =P
As for your next post, I've been toying with that for about half an hour now and I'm not getting it to work. It's either giving me random syntax errors, or not displaying anything. I tried messing with it before releasing this modification, but I couldn't get it to work then either. >_<; I'm basically using a spacer.gif as a noavatar.gif. If you're able to make it work, I'll gladly add it in.
foulplay
04-12-2006, 07:08 AM
Love the hack! *clicks installs* and rates thread 5 stars!
futuredood
06-29-2006, 03:27 AM
is their any way to get other custom things in here.. such as profile picture?
evenmonkeys
06-29-2006, 03:46 AM
As of now, I am not able to get that working right. I have the right hooks that are used in the memberinfo template to run the queries, but it's not working right. If someone's able to help me out with that, I'll gladly add it in. =\
Wordplay
06-29-2006, 06:25 AM
i love the idea but if this is the case, how do people check their reputation? anyway to have a different page just for reputation?
evenmonkeys
06-30-2006, 03:06 AM
Hmm... looks like I forgot that part. I'll have to add that in.
futuredood
06-30-2006, 06:17 AM
Yarub pleeeease try to get the Profile Picture working and updating in the CP. It seems to be such a simple bug that nobody can seem to get working!
Snake
06-30-2006, 05:20 PM
Yarub, think you could create the usercp page exactly to look like this?
http://img450.imageshack.us/img450/1551/newusercp5zr.jpg
I'm really looking forward to that!
Shazz
06-30-2006, 05:24 PM
thanks.
________
Motor Triathlon Race Car (http://www.toyota-wiki.com/wiki/Toyota_Motor_Triathlon_Race_Car)
evenmonkeys
06-30-2006, 07:41 PM
futuredood, I couldn't agree more. Honestly, it should be working. I really don't understand what's wrong with it. I've been playing with it over the past few nights, and I'll try to get it up as soon as possible.
Dark Cloud, I can try to do that, but that involves several different modifications and a lot more php coding than I can handle. I'm more of a template sort of guy. I just made this because I hated not seeing what I had, and I knew where all of the original queries were made. In any case, I'll see what I can do, but I can't guarantee anything. =\
Snake
07-01-2006, 08:56 AM
Okay cool, can't wait to see it though. Lemme know if ya have done something on that, alright?
futuredood
07-03-2006, 08:02 AM
just to note, i got the usergroups to show up in my profile.. i just had to reverse the if conditions lol.
ryans
07-09-2006, 04:00 PM
is their any way to get other custom things in here.. such as profile picture?
Any update on this? :) :)
evenmonkeys
07-09-2006, 08:44 PM
Not yet. I don't really know what else to try. Like I said before, I'm more of a templater than I am a coder. So if anyone else can assist with it, I'd be more than happy to add it in.
Darkfire122333
09-26-2006, 09:48 PM
Very nice addition, It looks really good, I would help you out on the code, but I am also just a templater. The avatar is just a code that allows for the dateline to run, I have found it once before, i will go back and look through my history and look for it again, I was also stuck on this back when I was working on my "Another UserCP Re-Write" for 3.5.3...
Shazz
09-26-2006, 09:54 PM
Database errors on 3.6.x...
Antivirus
09-27-2006, 01:33 AM
nice job, and a good idea as well!
evenmonkeys
09-27-2006, 04:36 AM
Database errors on 3.6.x...
I haven't made a version of it yet for 3.6.x. I may toy around with it sometime, but I hate php. =D
vBulletin® v3.8.12 by vBS, Copyright ©2000-2024, vBulletin Solutions Inc.