| User | Post |
|
11:30 am 25 Oct 2007
| angelic007
Member
| | Bologna, Italy | |
|
| posts 66 |
|
|
Hi, it would be nice for me to have the opportunity of automatically having the avatar that the users chose with cmdavatars plugin.
It’s really a simple plugin, the users only have to upload their avatar on WP admin panel and the avatar is shown across the entire site (where I put cmd_show_avatar(); in the template).
I think it should be quite easy to replace users’ forum’s avatar with a call to cmd_show_avatar() and show the same avatar used across the rest of WP without asking users to upload a new one...But maybe I'm wrong?
Please let me know !
Sorry for my english and thanks for your support.
Alessandro
|
|
|
|
|
I think the main problem there is that Gravatars seem more popular as they are global, not just confined to WP. I’m not sure how easy it would be to support both…
Does anyone else feel stringly about this?
|
|
|
2:34 pm 25 Oct 2007
| angelic007
Member
| | Bologna, Italy | |
|
| posts 66 |
|
|
Yes, i think you’re right.
But in Italy, my country, gravatars are not so popular yet.
I’ll work on this, and let you know about my results.
Thanks for the quick reply,
Alessandro
|
|
|
10:41 am 30 Oct 2007
| angelic007
Member
| | Bologna, Italy | |
|
| posts 66 |
|
|
Well, I did It.
It took about one hour to integrate Simple Forum with WP CMDAvatar, one of the most simple avatar plugin. If interested, I can post the patch here
|
|
|
|
|
Sounds good. Can you email it to me. I’ll send you an email with my address.
|
|
|
9:19 am 9 Nov 2007
| edwood
Guest
| | | |
|
| |
|
|
angelic007 said:
Well, I did It.
It took about one hour to integrate Simple Forum with WP CMDAvatar, one of the most simple avatar plugin. If interested, I can post the patch here
Could you please post the patch?
Thanks
|
|
|
1:31 am 10 Nov 2007
| edwood
Guest
| | | |
|
| |
|
|
Made my own patch
First change the path in sf-include.php to your cmdavatar directory.
here:
define(’SFAVATARS’, ABSPATH.’wp-content/avatars/’);
define(’SFAVATARURL’, $siteurl.’wp-content/avatars/’);
next in sf-pagecomponents.php change/add the following lines:
case ‘user’:
if(!empty($user_id)) $image=get_user_option(’sfavatar’, $user_id);
if(empty($image)) $image=$user_id.’.jpg’;
else
if(empty($image)) $image=$user_id.’.png’;
else
if(empty($image)) $image=$user_id.’.gif’;
break;
One hour thinking, 5 minuts to work ;-)
|
|
|
2:39 pm 21 May 2008
| Tirwin
Guest
| | | |
|
| |
|
|
Is it possible to program it so that, in wordpress, the end user has the ability to change their avatar. At the moment, the only available optoin seems to be for me to delete it for them and then for them to upload a new one?
|
|
|
|
|
Are you meaning the forum and uploading via profile? If so… hy can't they do this themselves?
|
|
|
10:12 am 22 May 2008
| Tirwin
Guest
| | | |
|
| |
|
|
Well on my wp site ( http://www.tirwin.co.uk and still under construction so ignore the horrible colours) when you signup you can upload an avatar, but there is no option for the user to delete their current one or upload a new one to overwrite it…. not as far as I can see. I have to go into the FTP folder and manually delete the original one so they can upload a new one.
|
|
|
|
|
really? So when a user (already with an avatar uploaded) loads up the profile screen are you saying that thre ability to upload another is not there? I will check on the deletion but I rather thought they could still upload…
|
|
|
7:08 pm 22 May 2008
| -Radio-
Moderator
| | Florida - USA | |
|
| posts 481 |
|
|
@tirwin
Sorry, but the site you linked us too desn't seem to have SPF active. I'm getting a blank page when I click on the (white text on yellow background) link to the forum.
Given the background v. layout issues the site is having, you have a few bigger problems than SPF.
|
|
|
9:12 am 23 May 2008
| Tirwin
Guest
| | | |
|
| |
|
|
Lol, I told you the design isn't finished… ignore all that, the forum page is literally jsut a WP page with nothing on it. Im installing Simple:Forum as we speek.
My problem was that when users sign up for a WP account on my site (login at very bottom of page) they can only upload the avatar once as detailed above. This is a WP problem not a simple forums problem. However, since Im about to install simple forum and was going to make use of the details in this spread for linking the avatars, I thought you guys might know why wordpress only lets my users upload 1 avatar then it cannot be deleted or overwritten?
|
|
|
|
|
I'm a little lost on this. Are you referring to the Simple:Press Forum option on the users profile screen to upload avatars? Any problem in there is nothing to do with WordPress. I have changed my avatar a couple of times with no hitch but I do agree that the old entry was not removed and that IS somethign I have logged as a bug. But I can stil upload a new one…
|
|
|
9:45 am 23 May 2008
| Tirwin
Guest
| | | |
|
| |
|
|
On another note, your help will not go un-noticed, as soon as the site is released there will be credit given for the your assistance… Im not welching hah
|
|
|
10:08 am 23 May 2008
| Tirwin
Guest
| | | |
|
| |
|
|
No Im using the CMD-Avatar plugin on wordpress. Is there a better option? My plan is to have wordpress and simple forum using the same avatar if possible?
|
|
|
|
|
I guess the most obvious option is gravatar.com which both the forum and WP support.
Within the forum you can upload personal avatars and there is a tag available to utilise that within non-forum areas.
The only problem I see with your plan is that the forum code will have to be hacked bt f that is OK then fine. It's at least a pluggable function.
|
|
|
11:06 am 23 May 2008
| Tirwin
Guest
| | | |
|
| |
|
|
So, running it the way I currently have it, I will not be able to change the avatar pic on WP but if I link the WP to the SF by 'hacking' (shouldn't be a problem) it then I will have the option to change it on the SF? I'll give it a go sometime soon and let you know I suppose… for future referance.
|
|
|
|
|
Oh no. I doubt that would work.. Although that depends where your cmdavatar stores the files. if it can be the same place as the forum (wp-content/forum-avatars) then yes - you should be able to do that.
|
|
|
12:02 pm 23 May 2008
| Tirwin
Guest
| | | |
|
| |
|
|
well, Ill try installing the forum then hacking the CMD-Avatars code to redirect it's avatar sorce to that folder… see if it works. I can't do anything just now as Im at work ¬_¬ but I'll let you know how it goes.
|
|
|
9:48 am 26 May 2008
| Tirwin
Guest
| | | |
|
| |
|
|
edwood said:
Made my own patch 
First change the path in sf-include.php to your cmdavatar directory.
here:
define(’SFAVATARS’, ABSPATH.’wp-content/avatars/’);
define(’SFAVATARURL’, $siteurl.’wp-content/avatars/’);
next in sf-pagecomponents.php change/add the following lines:
case ‘user’:
if(!empty($user_id)) $image=get_user_option(’sfavatar’, $user_id);
if(empty($image)) $image=$user_id.’.jpg’;
else
if(empty($image)) $image=$user_id.’.png’;
else
if(empty($image)) $image=$user_id.’.gif’;
break;
One hour thinking, 5 minuts to work ;-)
He says “next in sf-pagecomponents.php change/add the following lines:” any idea WHERE in the cript I should add this?
|
|
|
|
|
Note that from 3.1 onwards the forum Avatar setting is no longer to be found in the wp Usermeta table (which the function get_user_option() references). You will need to change that to:
sf_get_member_item($user_id, 'avatar')
|
|
|
10:25 am 26 May 2008
| Tirwin
Guest
| | | |
|
| |
|
|
Im not as clever as you may have first thought lol. I have done step one with no problems. On step 2 exactly what code are you suggesting I put in what file, and where? I'll let you know if it works.
|
|
|
|
|
I have no idea what you mean by step 1 and step 2. I was simply pointing out that in the code you published (post 21) you used the function get_user_option() in this line:
if(!empty($user_id)) $image=get_user_option('sfavatar', $user_id);
In any version of the forum above 3.1 the avatar file name is no longer available from the table that get_user_option() utilises. In other words you need to replace that line with its equivalent which is:
if(!empty($user_id)) $image=sf_get_member_item($user_id, 'avatar');
|
|
|
1:56 pm 26 May 2008
| Tirwin
Guest
| | | |
|
| |
|
|
is there a code that calls the avatar?
example: <?php sf_show_avatar(); ?>
if so, would it not be possible to simply insert this code where you would like your users avatars to display on the sites design and it would call it for you?
|
|