Back to vBulletin 3.5 Add-ons

New Members Page
Mod Version: 1.0.2, by Eric

This modification is in the archives.
vB Version: 3.5.5 Rating: (0 vote - 0 average) Installs: 12
Released: 07 Aug 2006 Last Update: 11 Aug 2006 Downloads: 26
Not Supported Uses Plugins Template Edits Additional Files  

New Members Page

Updated to 1.0.2

This modification will produce a New Members page listing the username, avatar, and profile pic of the latest users sorted by joindate. The amount listed is based on an admin configurable limit. If the user has no avatar or profile pic, a default one is used.

Made by request: index.php?t=122676

Installation
  • Import the product 'product-newmemberspage.xml'.
  • Upload newmembers.php to your forum root. Upload noavatar.gif and noprofilepic.gif to images/misc/. If you want to use your own remember that you will have to go into the admincp and give it's filename + size.
  • Options can be set in AdminCP -> vBulletin Options -> New Members Page

That's it your done.. aside from linking to the newmembers page. Here's an example of adding it to the navbar:

Open the 'navbar' template.

FIND
HTML Code:
<td class="vbmenu_control"><a href="calendar.php$session[sessionurl_q]">$vbphrase[calendar]</a></td>
AFTER, ADD
HTML Code:
<td class="vbmenu_control"><a href="newmembers.php$session[sessionurl_q]">$vbphrase[newmembers]</a></td>
Upgrading
  • Re-import the product 'product-newmemberspage.xml' with "Allow Overwrite" set to yes.
  • Re-upload & overwrite newmembers.php.

Changelog
  • 1.0.2 - Re-added the 'cutoff'. It is based on an admin set number of days.
  • 1.0.1 - Removed the time restriction: 'cutoff'. Cleaned up the newmembers_results template.

WOL & Joindate
If you want New Members Page on WOL and/or display joindate on the New Members Page, make the edits in the following posts:

Spoiler (click to open)


Quote by Stifmeister2
LOL don't ask me I'm a n00b when it comes to coding.
For WOL, you'll need two plugins.

online_location_process:
PHP Code:
if ($filename == 'newmembers.php')
{
    
$userinfo['activity'] = 'newmembers';

online_location_unknown:
PHP Code:
if ($userinfo['activity'] == 'newmembers')
{
    
$userinfo['action'] = construct_phrase($vbphrase['viewing_x'], 'New Members');
    
$handled true;

For joindate; open newmembers.php and find:
PHP Code:
        $bgclass 'alt2'
Above that add:
PHP Code:
        $newmembers['datejoined'] = vbdate($vbulletin->options['dateformat'], $newmembers['joindate'], true); 
Edit the newmembers template, find
HTML Code:
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
<tr align="center">
	<td class="thead" align="$stylevar[left]" nowrap="nowrap">$vbphrase[username]</td>
	<td class="thead" nowrap="nowrap">$vbphrase[avatar]</td>
	<td class="thead" nowrap="nowrap">$vbphrase[profile_picture]</td>
</tr>
$newmemberbits
</table>
Replace with
HTML Code:
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
<tr align="center">
	<td class="thead" align="$stylevar[left]" nowrap="nowrap">$vbphrase[username]</td>
	<td class="thead" nowrap="nowrap">$vbphrase[avatar]</td>
	<td class="thead" nowrap="nowrap">$vbphrase[profile_picture]</td>
	<td class="thead" nowrap="nowrap">$vbphrase[join_date]</td>
</tr>
$newmemberbits
</table>
Edit the 'newmembers_results' template. Replace everything with:
HTML Code:
<tr align="center">
	<td class="alt1Active" align="$stylevar[left]" id="u$newmembers[userid]"><a href="member.php?$session[sessionurl]u=$newmembers[userid]">$newmembers[username]</a></td>
	<if condition="exec_switch_bg()"><td class="$bgclass"><img src="$avatarurl" border="0" $avwidth $avheight alt="<phrase 1="$newmembers[username]">$vbphrase[xs_avatar]</phrase>" hspace="4" vspace="4" /></td></if>
	<if condition="exec_switch_bg()"><td class="$bgclass">$newmembers[profilepic]</td></if>
	<if condition="exec_switch_bg()"><td class="$bgclass">$newmembers[datejoined]</td></if>
</tr>
That should do it. Of course you can change the template around etc to get it where you want.

Close

Spoiler (click to open)


Quote by Stifmeister2
Hmm it says everyone has joined "01-01-1970".. :S
Let me take a look into that.

EDIT: oops, my bad :red:

Forgot to add something to the query, open newmembers.php and find:
PHP Code:
    $getnewmembers $db->query_read("
        SELECT user.userid, user.username, avatar.avatarpath, NOT ISNULL(customavatar.userid) AS hascustomavatar, customavatar.dateline AS avatardateline, customavatar.width AS avwidth, customavatar.height AS avheight, customprofilepic.userid AS profilepic, customprofilepic.dateline AS profilepicdateline, customprofilepic.width AS ppwidth, customprofilepic.height AS ppheight
        FROM " 
TABLE_PREFIX "user AS user
        LEFT JOIN " 
TABLE_PREFIX "avatar AS avatar ON(avatar.avatarid = user.avatarid)
        LEFT JOIN " 
TABLE_PREFIX "customavatar AS customavatar ON(customavatar.userid = user.userid)
        LEFT JOIN " 
TABLE_PREFIX "customprofilepic AS customprofilepic ON (user.userid = customprofilepic.userid)
        WHERE user.joindate >= 
$cutoff
        ORDER BY user.joindate DESC
        LIMIT " 
. ($limitlower 1) . ", $perpage
    "
); 
Replace with
PHP Code:
    $getnewmembers $db->query_read("
        SELECT user.userid, user.username, user.joindate, avatar.avatarpath, NOT ISNULL(customavatar.userid) AS hascustomavatar, customavatar.dateline AS avatardateline, customavatar.width AS avwidth, customavatar.height AS avheight, customprofilepic.userid AS profilepic, customprofilepic.dateline AS profilepicdateline, customprofilepic.width AS ppwidth, customprofilepic.height AS ppheight
        FROM " 
TABLE_PREFIX "user AS user
        LEFT JOIN " 
TABLE_PREFIX "avatar AS avatar ON(avatar.avatarid = user.avatarid)
        LEFT JOIN " 
TABLE_PREFIX "customavatar AS customavatar ON(customavatar.userid = user.userid)
        LEFT JOIN " 
TABLE_PREFIX "customprofilepic AS customprofilepic ON (user.userid = customprofilepic.userid)
        WHERE user.joindate >= 
$cutoff
        ORDER BY user.joindate DESC
        LIMIT " 
. ($limitlower 1) . ", $perpage
    "
); 

Close


Make sure you click if you use this modification.

Enjoy!

Download

This modification is archived and cannot be downloaded.

Screenshots

   

Similar Mods

Miscellaneous Hacks New Members Page vBulletin 3.6 Add-ons

vblts.ru supports vBulletin®, 2022-2025