<% lvl=validate(0) psql="SELECT * from xlaALSUsers order by status desc,attending desc" set conn=server.createobject("ADODB.Connection") conn.open connection response.buffer=true response.flush %> Reprentative's Availability <% set rs=conn.execute(psql) c=0 do until rs.eof c=c+1 name=rs("name") userid=rs("userid") attending=rs("attending") lastlogin=rs("lastlogin") if lastlogin<>"" then timeonline=datediff("n",lastlogin,now) else timeonline=" - " status=rs("status") if status=0 then imgstatus="imgOffline.gif" else imgstatus="imgOnline.gif" if status=0 then timeonline=" - " %> <% rs.movenext loop rs.close set rs=nothing conn.close set conn=nothing %>
User Attending Time On-line Status
<%=name%> <%=attending%> <%=timeonline%>
<%=whichstatus(status)%>