PDA

View Full Version : Mini Mods - Display Friend count in Posbit


mvigod
06-11-2008, 10:00 PM
One of our members asked for this so I figured I would do a quick share here.

Go to AdminCP> Styles & Templates> Postbit Legacy.

Find:
<div>$post[icqicon] $post[aimicon] $post[msnicon] $post[yahooicon] $post[skypeicon]</div>
</div> Below that add:

<if condition="$post['userid']"><div>Friends: (<b><a href="member.php?u=$post[userid]">$post[friendcount]</a></b>)</div></if>Thats it. Easy breezy. If you use itrader or an award mod, you can place it below the code for that as I have done.

Coop1979
06-12-2008, 12:53 PM
Nice change! It would be nice if you could get it to load directly to the Friends tab. I tried to add "#friends" to the end of the url, but it didn't work.

M-Tuning
06-12-2008, 03:04 PM
Thanks, never thought of that.

redraider
06-12-2008, 06:19 PM
Great one. Could we have similar for number of social groups?

mvigod
06-13-2008, 12:19 PM
Nice change! It would be nice if you could get it to load directly to the Friends tab. I tried to add "#friends" to the end of the url, but it didn't work.
Yeah, it won't recognize the anchor #friends when entering the profiile. I tried it too, and ended up just leading the link to the profile page. I am sure there is a way and I'll look at it when I get some time.


Great one. Could we have similar for number of social groups?

I am not sure if there is a system count for social groups, but Ill look. If there is, it should be fairly simple.

Shill360
06-13-2008, 09:57 PM
If you download the friends browser mod you can then change the link to point to friends.php?u=$post[userid] which is what i've done.

Boofo
06-13-2008, 10:18 PM
What is the "friends browser mod"?

BigDog56
06-14-2008, 12:11 PM
Very nice, thank you. I placed it a little differently, in postbit. not postbit legacy.

<if condition="$show['reputation']"><if condition="$show['reppower']">$vbphrase[reppower]: <span id="reppower_$post[postid]_$post[userid]">$post[reppower]</span> </if><div><span id="repdisplay_$post[postid]_$post[userid]">$post[reputationdisplay]</span></div></if>

And placed above it.

<if condition="$post['userid']"><div>Friends: (<b><a href="member.php?u=$post[userid]">$post[friendcount]</a></b>)</div></if>

Nice location for me. Again, THANK YOU!

mvigod
06-14-2008, 03:15 PM
If you download the friends browser mod you can then change the link to point to friends.php?u=$post[userid] which is what i've done.
I agree with Boofo, havent heard of that one.

mvigod
06-14-2008, 03:16 PM
Very nice, thank you. I placed it a little differently, in postbit. not postbit legacy.

<if condition="$show['reputation']"><if condition="$show['reppower']">$vbphrase[reppower]: <span id="reppower_$post[postid]_$post[userid]">$post[reppower]</span> </if><div><span id="repdisplay_$post[postid]_$post[userid]">$post[reputationdisplay]</span></div></if>And placed above it.

<if condition="$post['userid']"><div>Friends: (<b><a href="member.php?u=$post[userid]">$post[friendcount]</a></b>)</div></if>Nice location for me. Again, THANK YOU!
No problem. Thanks for sharing your postbit placement.

mA|tRiX
07-04-2008, 10:17 AM
THX. Works great :)

010081
07-05-2008, 09:39 AM
worked great thankx.

Q-v-n-s-Q
07-29-2008, 07:30 AM
nice liltle mod, thanks

bongwater
07-29-2008, 12:51 PM
havent installed this mod (yet), but I was wondering - Is the count of 0 displayed if a user doesnt have any added friends?

hotwheels
08-01-2008, 04:27 AM
Yes to the above question...............

beckyvan
08-01-2008, 08:27 PM
Very cool, thanks!

beckyvan
08-03-2008, 01:14 AM
Can this be edited to not display for certain users. I have about 10 users that don't like it. Is there a condition I can put in by user id somewhere?

BucWiLd
08-11-2008, 05:13 AM
nice hack, thanks

Regs
08-11-2008, 02:00 PM
Very nice, thank you.

I needed to place it ever-so-slightly different than the instructions provided in order to keep the font size consistent with other postbit, erm, bits :) (copy the code supplied and paste right above the last </div> in the code to search for)

That's probably not too clear, but this post is unsupported.

:D

biggeorge
02-14-2009, 01:56 PM
Thanks!