0) { pwg_query("INSERT INTO `". USER_INFO_TRACKING_TABLE2 ."`( userID, userName, ipAddress, timeStamp, action ) VALUES( '". $userNameLookup[0] ."', '". $_POST['username'] ."', '". $myIpAddress ."', '". time() ."', 'Failed Login' );"); } else { pwg_query("INSERT INTO `". USER_INFO_TRACKING_TABLE2 ."`( userName, ipAddress, timeStamp, action ) VALUES( '". $_POST['username'] ."', '". $myIpAddress ."', '". time() ."', 'Failed Login' );"); } } /** * Triggered on logout * */ function ui_logout() { global $conf, $user; include_once(PHPWG_ROOT_PATH.'admin/include/functions.php'); $myIpAddress = $_SERVER['REMOTE_ADDR']; pwg_query("INSERT INTO `". USER_INFO_TRACKING_TABLE2 ."`( userID, userName, ipAddress, timeStamp, action ) VALUES( '". $user['id'] ."', '". $user['username'] ."', '". $myIpAddress ."', '". time() ."', 'Logout' );"); } ?>