You are here

function flood_register_event in Drupal 6

Same name and namespace in other branches
  1. 4 includes/common.inc \flood_register_event()
  2. 5 includes/common.inc \flood_register_event()
  3. 7 includes/common.inc \flood_register_event()

Register an event for the current visitor (hostname/IP) to the flood control mechanism.

Parameters

$name: The name of an event.

2 calls to flood_register_event()
contact_mail_page_submit in modules/contact/contact.pages.inc
Process the site-wide contact page form submission.
contact_mail_user_submit in modules/contact/contact.pages.inc
Process the personal contact page form submission.

File

includes/common.inc, line 1084
Common functions that many Drupal modules will need to reference.

Code

function flood_register_event($name) {
  db_query("INSERT INTO {flood} (event, hostname, timestamp) VALUES ('%s', '%s', %d)", $name, ip_address(), time());
}