1
antifmradio
random members block ?

I looked through my stuff
i didnt notice one but then again
i dont even know if it exists or not lol


Ok so, is there a RANDOM MEMBERS block?
Right now im using the TOP POSTERS block vertically
but wanted to randomize the people listed.

2
demian
Re: random members block ?
  • 2008/7/22 19:02

  • demian

  • Quite a regular

  • Posts: 225

  • Since: 2008/4/29



3
demian
Re: random members block ?
  • 2008/7/22 19:13

  • demian

  • Quite a regular

  • Posts: 225

  • Since: 2008/4/29



4
antifmradio
Re: random members block ?

ok i got this one working for me

global $xoopsDB;
$sql = "SELECT uid, uname, user_avatar FROM ".$xoopsDB->prefix("users")." WHERE level > 0 AND uid NOT IN (1) AND user_avatar <> 'blank.gif' ORDER BY RAND() LIMIT 10";
$result = $xoopsDB->query($sql);
while (list($uid, $uname,$user_avatar) = $xoopsDB->fetchRow($result) )
{
echo "<img src='./uploads/".$user_avatar."'alt='Avatar'></a><br />";
echo "<a href='".XOOPS_URL."/userinfo.php?uid=".$uid."'>".$uname."</a><br />";
}

Login

Who's Online

232 user(s) are online (159 user(s) are browsing Support Forums)


Members: 0


Guests: 232


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: May 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits