本文整理汇总了PHP中Logging::changelog_send_mail方法的典型用法代码示例。如果您正苦于以下问题:PHP Logging::changelog_send_mail方法的具体用法?PHP Logging::changelog_send_mail怎么用?PHP Logging::changelog_send_mail使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Logging
的用法示例。
在下文中一共展示了Logging::changelog_send_mail方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1:
if (isset($errors)) {
$log = $Result->array_to_log($errors);
$Result->show("danger", $log, false);
$Log->write("IP address modification", "'Error {$action} range {$address['start']} - {$address['stop']}<br> {$log}", 2);
} else {
# reset IP for mailing
$address['ip_addr'] = $address['start'] . ' - ' . $address['stop'];
# log and changelog
$Result->show("success", _("Range") . " {$address['start']} - {$address['stop']} " . _($action) . " " . _("successfull") . "!", false);
$Log->write("IP address modification", "Range {$address['start']} - {$address['stop']} {$action} successfull!", 0);
# send changelog mail
$Log->object_action = $action;
$Log->object_type = "address range";
$Log->object_result = "success";
$Log->user = $User->user;
$Log->changelog_send_mail("Address range {$address['start']} - {$address['stop']} {$action}");
}
}
} else {
# unique hostname requested?
if (isset($address['unique'])) {
if ($address['unique'] == 1 && strlen($address['dns_name']) > 0) {
# check if unique
if (!$Addresses->is_hostname_unique($address['dns_name'])) {
$Result->show("danger", _('Hostname is not unique') . "!", true);
}
}
}
# validate and normalize MAC address
if ($action !== "delete") {
if (strlen(@$address['mac']) > 0) {