Register Members List Search Today's Posts Mark Forums Read

Reply
 
Thread Tools
  #1  
Old 11 May 2012, 09:04
KimK KimK is offline
 
Join Date: Feb 2012
Real name: Kim
How can I create Friends widget on the home page

Hello,
I need to create a widget on the home page that shows my friends like the widget on my profile. But I don't know how. Can anyone help me with this

I just need to know the code that I can use on the widget to show my friends (Maybe limit the friends widget to show 6 friends only).

I attached an image for the widget that I want to create one like it on the home page.

Thanks a lot,
Attached Images
File Type: jpg friends widget.jpg (55.8 KB, 62 views)
Reply With Quote
  #2  
Old 11 May 2012, 13:06
kh99 kh99 is offline
 
Join Date: Aug 2009
Real name: Kevin
You could show up to 6 random friends like this:


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Reply With Quote
  #3  
Old 11 May 2012, 17:52
KimK KimK is offline
 
Join Date: Feb 2012
Real name: Kim
Thank you kh99 for your reply. But could you please teach me how to add your code in widget on the home page. Because I created a new HTML static widget and I paste your code into the widget but when I browsed the Home Page I found the widget shows your code as it is. So I replaced the HTML Static widget with PHP Direct Execution widget and when I browsed the Home Page I found the date of today showing up only in the widget.

Can you help me please. I don't know where's the problem.
Reply With Quote
  #4  
Old 11 May 2012, 18:52
kh99 kh99 is offline
 
Join Date: Aug 2009
Real name: Kevin
The php direct execution widget should work. By default the "configure" text area has a sample line of code that displays the date. You need to make sure you remove that.
Reply With Quote
  #5  
Old 12 May 2012, 01:09
KimK KimK is offline
 
Join Date: Feb 2012
Real name: Kim
Hi kh99,
You are absolutely right. I used php direct execution widget and I replaced the code for the date with your code and the widget works fine now. But is there any chance to list the names of my friends with their profile photos as in the friends widget in my profile (see the attached image in the first post)??
Reply With Quote
  #6  
Old 12 May 2012, 01:29
kh99 kh99 is offline
 
Join Date: Aug 2009
Real name: Kevin
I've started working on something like that. Hopefully it won't take too long (and hopefully I'll actually finish ).
Reply With Quote
  #7  
Old 12 May 2012, 11:19
KimK KimK is offline
 
Join Date: Feb 2012
Real name: Kim
A million thanks to you Kh99. I wish you best of luck with the developing of this widget.
I'll keep monitoring your progress with joy!
Reply With Quote
  #8  
Old 14 Nov 2012, 16:43
s_cocis s_cocis is offline
 
Join Date: Nov 2011
very good !
Reply With Quote
  #9  
Old 30 Sep 2013, 06:07
CAG CheechDogg's Avatar
CAG CheechDogg CAG CheechDogg is offline
 
Join Date: Feb 2012
To show all your friends online in a widget you would use this:


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

If you see this kh99 would you be kind enough my Man to modify it so that it shows the markups to show the different user groups and comma list after each member ?
Reply With Quote
  #10  
Old 30 Sep 2013, 12:45
kh99 kh99 is offline
 
Join Date: Aug 2009
Real name: Kevin
lol, I guess I never did finish this. Anyway, I haven't tried it but I think something like this should work:


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.


Last edited by kh99; 30 Sep 2013 at 16:33. Reason: added comma separation, global statement
Reply With Quote
  #11  
Old 30 Sep 2013, 16:29
CAG CheechDogg's Avatar
CAG CheechDogg CAG CheechDogg is offline
 
Join Date: Feb 2012
I am gonnah cry from joy! lol ...Works great kh99 thank you once again !

Just a quick note, you must include at the very top of the code the following if not the widget will not show up.

global $vbulletin;
Reply With Quote
  #12  
Old 30 Sep 2013, 16:33
kh99 kh99 is offline
 
Join Date: Aug 2009
Real name: Kevin
Originally Posted by CAG CheechDogg View Post
Just a quick note, you must include at the very top of the code the following if not the widget will not show up.

global $vbulletin;

Thanks, I added it above. I guess I missed it when I copy/pasted the code.
Reply With Quote
  #13  
Old 30 Sep 2013, 17:14
CAG CheechDogg's Avatar
CAG CheechDogg CAG CheechDogg is offline
 
Join Date: Feb 2012
Yeerp, thank you kh99 once again my Man you rock!
Reply With Quote
  #14  
Old 24 Oct 2013, 11:21
jimsflies jimsflies is offline
 
Join Date: Aug 2009
Could this be turned into a forum block too? If so, how?
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


New To Site? Need Help?

All times are GMT. The time now is 08:36.

Layout Options | Width: Wide Color: