nice youtube extention. I'll definitely use it.

2

(119 replies, posted in PunBB 1.3 extensions)

but the current one looks nice smile

hmm ... I have got to read about them ... learn how to make then ... smile

well, don't know how to do it mad, anyway, I think if you use a several extentions, they could not be friendly with others ... that's why it's better to have manually installed mod.

Title: Last 24 hours visited users
Description: Lists all users who have visited the forum last 24 hours.
Author: mzonas (mzonas1989@gmail.com)
Admin Notes: I didn't copy anyone's work. I just made it by myself as I didn't see any other mod like this.
Installation:

open footer.php

-----[FIND]-----
        // If there are registered users logged in, list them
        if (count($users) > 0)
            echo "\t\t\t".'<p>'.implode(', ', $users).'</p>'."\n";

?>
        </div>
<?php

    }

-----[ADD, AFTER]-----
        // 24 last visitors
        $query_time = time() - 86400;
        $query = array(
            'SELECT' => 'u.id, u.username',
            'FROM' => 'users AS u',
            'WHERE' => 'u.last_visit >= \'$query_time\' AND u.id > 1',
            'ORDER BY' => 'u.username'
        );

        $result = $db->query_build($query, true) or error(__FILE__, __LINE__);
        $num_users_last24 = 0;
        $users24 = array();

            while ($pun_last24_users = $db->fetch_assoc($result))
            {
                if ($pun_last24_users['id'] > 1)
                    $users24[] = '<a href="'.pun_link($pun_url['user'], $pun_last24_users['id']).'">'.htmlspecialchars($pun_last24_users['username']).'</a>';
                    ++$num_users_last24;
            }

?>
            <div id="onlinelist">
                <h3><?php printf($lang_index['Online24'], $num_users_last24) ?></h3>

<?php

            if ($num_users_last24 > 0)
                echo "\t\t\t".'<p>'.implode(', ', $users24).'</p>'."\n";

?>

        </div>

open lang/English/index.php

-----[FIND]-----
'Online'                =>    '<strong>Online</strong> ( Guests: <strong>%s</strong> | Registered users: <strong>%s</strong> )',    // As in "Online: User A, User B etc."

-----[ADD, AFTER]-----
'Online24'              =>  '%s users have visited the forums last 24 hours: ',

All you have to do now is to save your files and upload to your server. Enjoy wink