lol, let me know if you come up with a cleaner code... just keep in mind this code is also customizable for various things so we don't want to delete things that are currently not in use in the code necessairily. Cleaning up for errors though is great... I am not a PHP specialist like some here.
I have been using the code as it is for about 7 months now and it is in every release of BF Vista out there working as well too.

















