function linkchecker_watchdog_log in Link checker 7
Same name and namespace in other branches
- 8 linkchecker.module \linkchecker_watchdog_log()
Conditionally logs a system message.
Parameters
$type: The category to which this message belongs. Can be any string, but the general practice is to use the name of the module calling watchdog().
$message: The message to store in the log. Keep $message translatable by not concatenating dynamic values into it! Variables in the message should be added by using placeholder strings alongside the variables argument to declare the value of the placeholders. See t() for documentation on how $message and $variables interact.
$variables: Array of variables to replace in the message on display or NULL if message is already translated or not possible to translate.
$severity: The severity of the message; one of the following values as defined in RFC 3164:
- WATCHDOG_EMERGENCY: Emergency, system is unusable.
- WATCHDOG_ALERT: Alert, action must be taken immediately.
- WATCHDOG_CRITICAL: Critical conditions.
- WATCHDOG_ERROR: Error conditions.
- WATCHDOG_WARNING: Warning conditions.
- WATCHDOG_NOTICE: (default) Normal but significant conditions.
- WATCHDOG_INFO: Informational messages.
- WATCHDOG_DEBUG: Debug-level messages.
$link: A link to associate with the message.
See also
watchdog()
4 calls to linkchecker_watchdog_log()
- _linkchecker_check_links in ./
linkchecker.module - Run link checks.
- _linkchecker_check_markup in ./
linkchecker.module - Customized clone of core check_markup() with additional filter blacklist.
- _linkchecker_status_handling in ./
linkchecker.module - Status code handling.
- _linkchecker_unpublish_nodes in ./
linkchecker.module - Unpublishes all nodes having the specified link id.
File
- ./
linkchecker.module, line 185 - This module periodically check links in given node types, blocks etc.
Code
function linkchecker_watchdog_log($type, $message, $variables = array(), $severity = WATCHDOG_NOTICE, $link = NULL) {
if ($severity <= variable_get('linkchecker_log_level', WATCHDOG_INFO)) {
watchdog($type, $message, $variables, $severity, $link);
}
}