예제 #1
0
function bb2_log_denial($settings, $package, $key, $previous_key = false)
{
    if (!$settings['logging']) {
        return;
    }
    bb2_db_query(bb2_insert($settings, $package, $key));
}
function bb2_approved($settings, $package)
{
    // Dirk wanted this
    if (is_callable('bb2_approved_callback')) {
        bb2_approved_callback($settings, $package);
    }
    // Decide what to log on approved requests.
    if ($settings['verbose'] && $settings['logging'] || empty($package['user_agent'])) {
        bb2_db_query(bb2_insert($settings, $package, "00000000"));
    }
}
예제 #3
0
function bb2_log_denial($settings, $package, $key, $previous_key = false)
{
    bb2_db_query(bb2_insert($settings, $package, $key));
}
예제 #4
0
function bb2_capture_spam($id, $comment)
{
    global $bb2_package;
    // Capture only spam
    if ('spam' != $comment->comment_approved) {
        return;
    }
    // Don't capture if HTTP request no longer active
    if (array_key_exists("request_entity", $bb2_package) && array_key_exists("author", $bb2_package['request_entity']) && $bb2_package['request_entity']['author'] == $comment->comment_author) {
        bb2_db_query(bb2_insert(bb2_read_settings(), $bb2_package, "00000000"));
    }
}