From: "CHAN YICK WAI" <[EMAIL PROTECTED]> > I'm writing an application that requires log every transactions users done, > e.g. update which record, delete which record, something like that. > > I guess one way is whenever I issue a mysql_query(), I also insert this > query in whole into another table together with the user name, so I can log > and retrieve it out for audit. > > Will you have that kind of experience? How can I do it comprehensively, e.g. > no too big additional coding effort, easy to manage, reliable, etc.
Sounds like you just need to write a wrapper for mysql_query() that logs what's going on. function my_mysql_query($query) { log_query($query); return mysql_query($query); } and use my_mysql_query() everywhere instead of mysql_query. ---John Holmes... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php