You need some type of user management metaphor.
Most track when a user logs in and keeps track of the user's activity with sessions and/or database inserts/selects.
Caveat: db inserts/selects can be very taxing on systems so beware.
If it's not a site with heavy traffic, and the user has JavaScript enabled, you could use some type of Ajax ping (say every minute or so) to detect if a user is still online.
(Still have to use a database or file though to pull it off.)
Since this bulletin board is based on vBulletin (which is not free) you might want to look at other bulletin board apps that are open source to see how they do it.
A popular board app is phpBB and you can start hunting here:
http://www.phpbb.com/community/viewtopic.php?f=71&t=986195
If JavaScript isn't enabled, you'd need some type of non-cookie session metaphor
i.e. pageonsite.php?sessid=sess_u8l5t7kj6t56m311vvj26qbfv6 and/or hidden input elements for form submissions.
Just a start to a non-trivial issue.
Hope that helps to a degree.