Random Member issue

Current Version: 1.0.6
Released: 09.01.10
Forum rules
Before creating a new support thread, please take a look in the board3 Portal FAQ and use the search!
Many questions have already been answered.
Locked
User avatar

Topic author
MrBaseball34
Valued Contributor
Posts: 64
Joined: 25. June 2009 00:15
phpBB.de User: MB34

Random Member issue

Post by MrBaseball34 »

Your Portal Version: 1.0.0RC3
Your phpBB Type: Standard phpBB3
MODs installed: No
Your knowledge: Beginner

What have you done before the problem was there?


What have you already tryed to solve the problem?


Description and Message
I modified the random_member block like I said in my replies to girlintrouble's question.

However, I don't want the block to show if there are no members returned from the query.
in random_member.php I made this change:

Code: Select all

$result = $db->sql_query_limit($sql, 1);
$member_count = $db->sql_affectedrows();
$row = $db->sql_fetchrow($result);
And this change:

Code: Select all

if ($member_count > 0) {
  $template->assign_vars(array(
	  'S_DISPLAY_RANDOM_MEMBER' => true,
  ));
} else {
  $template->assign_vars(array(
	  'S_DISPLAY_RANDOM_MEMBER' => false,
  ));
};
But I get no random members, even when I DO have some that opted in.
Any ideas why? If I remove the changes above, I get random members shown.[/i]
MrBaseball34
Hook 'em Horns
Image
2005 College Football National Champions
2005 College Baseball National Champions
User avatar

Topic author
MrBaseball34
Valued Contributor
Posts: 64
Joined: 25. June 2009 00:15
phpBB.de User: MB34

Re: Random Member issue

Post by MrBaseball34 »

Oh, heck, nevermind. I was filtering by #posts, also and none of the members had enough posts.
MrBaseball34
Hook 'em Horns
Image
2005 College Football National Champions
2005 College Baseball National Champions
Locked

Return to “board3 Portal 1.0.x - English Support”