Hi
You should really be checking if the query returns any thing, there is no sense doing a while() loop on a null returned result set! Also it would be better to do the link building inside the usersinoom() function and just return the links or if no users are in the room, just return "No Users In Room". It wasted coding to do (2) loops and if()s when you don't have to! Logic is missing from this!!!
Show me or tell me the database class you are using, and I will writre you how to do it the right way! I need to know the DB class to see if it has a function that returns the row count for the query!
Sonia!
|