For the cookies to work and update
Right now the lightbulbs stay on all the time.
You had meantioned you might have had a bit of code also in ubbthreads.php so that it would recognize and update the lightbulbs. Just like you had that query routine that got the counts for the thread totals and such.