From: <re...@ki...> - 2005-03-05 17:12:00
|
I'd like to change the "no" next to "in/out board" in the cms matrix for phpwebsite(http://www.cmsmatrix.org/matrix?func=3DviewDetail <http://www.cmsmatrix.org/matrix?func=3DviewDetail&wid=3D2&listingId=3D10= 57> &wid=3D2&listingId=3D1057) to a yes. writing such a module should be = pretty easy. It's just two tables: =20 one with mod_inoutboard_users(id, user_id, status_id, timestamp) and the second with mod_inoutboard_stati(status_id, caption). =20 my plan would be to show the status of the group(s) the current user is logged in to. in a box. all the time. it should be as easy as a=20 =20 select caption, username from mod_groups g left join mod_users u on u.group_id=3Dg.id left join mod_inoutboard_users iu on u.user_id=3Diu.user_id left join mod_inoutboard_stati s on s.status_id=3Diu.s having g.id=3D.... =20 the catch here is of course, that groups are stored in only one field. = in a compressed form, like 1:4:2. =20 does anyone have advice on how I'd select all users of a certain group efficiently? I'd need the user_ids, so I can join them with the rest. =20 thanks, =20 Ren=E9! |