Your Portal Version: 1.0.3
Your phpBB Type: Standard phpBB3
MODs installed: Yes
Your knowledge: Advanced Knowledge
Boardlink: http://www.handboogforum.nl
What have you done before the problem was there?
-
What have you already tryed to solve the problem?
-
Description and Message
Hi.
Is it possible to filter the members shown in the Random Member block to only show members who have 1 or more post(s)?
grtz,
Twan
Filter for the "Random Members" block
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.
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.
-
Topic author - Active Member
- Posts: 28
- Joined: 30. January 2009 12:17
- phpBB.com User: DutchToxophilite
- Location: Venlo, The Netherlands
- Contact:
Filter for the "Random Members" block
The joy's of Archery can be found anywhere. Far places only offer exotic ways to suffer.
Re: Filter for the "Random Members" block
Replace
With
Code: Select all
case 'postgres':
$sql = 'SELECT *
FROM ' . USERS_TABLE . '
WHERE user_type <> ' . USER_IGNORE . '
AND user_type <> ' . USER_INACTIVE . '
ORDER BY RANDOM()';
break;
case 'mssql':
case 'mssql_odbc':
$sql = 'SELECT *
FROM ' . USERS_TABLE . '
WHERE user_type <> ' . USER_IGNORE . '
AND user_type <> ' . USER_INACTIVE . '
ORDER BY NEWID()';
break;
default:
$sql = 'SELECT *
FROM ' . USERS_TABLE . '
WHERE user_type <> ' . USER_IGNORE . '
AND user_type <> ' . USER_INACTIVE . '
ORDER BY RAND()';
break;
Code: Select all
case 'postgres':
$sql = 'SELECT *
FROM ' . USERS_TABLE . '
WHERE user_type <> ' . USER_IGNORE . '
AND user_type <> ' . USER_INACTIVE . '
AND user_posts > 0
ORDER BY RANDOM()';
break;
case 'mssql':
case 'mssql_odbc':
$sql = 'SELECT *
FROM ' . USERS_TABLE . '
WHERE user_type <> ' . USER_IGNORE . '
AND user_type <> ' . USER_INACTIVE . '
AND user_posts > 0
ORDER BY NEWID()';
break;
default:
$sql = 'SELECT *
FROM ' . USERS_TABLE . '
WHERE user_type <> ' . USER_IGNORE . '
AND user_type <> ' . USER_INACTIVE . '
AND user_posts > 0
ORDER BY RAND()';
break;
Board3 Portal Dev & English Tech Support
-
Topic author - Active Member
- Posts: 28
- Joined: 30. January 2009 12:17
- phpBB.com User: DutchToxophilite
- Location: Venlo, The Netherlands
- Contact:
Re: Filter for the "Random Members" block
OK, but in what file?
edit: Oh, found it, random_member.php
Many Thanx
grtz,
Twan
edit: Oh, found it, random_member.php
Many Thanx
grtz,
Twan
Last edited by DutchToxophilite on 29. June 2009 14:36, edited 1 time in total.
The joy's of Archery can be found anywhere. Far places only offer exotic ways to suffer.
Re: Filter for the "Random Members" block
Whoops sorry, portal/block/random_member.php
Board3 Portal Dev & English Tech Support
-
Topic author - Active Member
- Posts: 28
- Joined: 30. January 2009 12:17
- phpBB.com User: DutchToxophilite
- Location: Venlo, The Netherlands
- Contact:
Re: Filter for the "Random Members" block
Sorry.
I forgot to answer this topic.
But It worked like a charm.
THANX
grtz,
Twan
I forgot to answer this topic.
But It worked like a charm.
THANX
grtz,
Twan
The joy's of Archery can be found anywhere. Far places only offer exotic ways to suffer.