本文整理匯總了PHP中maincf_multi::bann_destination_domains方法的典型用法代碼示例。如果您正苦於以下問題:PHP maincf_multi::bann_destination_domains方法的具體用法?PHP maincf_multi::bann_destination_domains怎麽用?PHP maincf_multi::bann_destination_domains使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類maincf_multi
的用法示例。
在下文中一共展示了maincf_multi::bann_destination_domains方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: build_transport_maps
function build_transport_maps()
{
if (!isset($GLOBALS["transport_maps_AT"])) {
$GLOBALS["transport_maps_AT"] = array();
}
$main = new maincf_multi("master", "master");
$main->bann_destination_domains();
$users = new usersMenus();
$CountDeMailMan = 0;
if (!is_file("/etc/postfix/transport.throttle")) {
@file_put_contents("/etc/postfix/transport.throttle", " ");
}
if (!is_array($GLOBALS["transport_maps"])) {
shell_exec("{$GLOBALS["postconf"]} -e \"transport_maps = hash:/etc/postfix/transport.throttle\" >/dev/null 2>&1");
}
if ($users->MAILMAN_INSTALLED) {
$GLOBALS["transport_maps"] = $main->mailman_transport($GLOBALS["transport_maps"]);
}
while (list($num, $ligne) = each($GLOBALS["transport_maps"])) {
if ($ligne == null) {
continue;
}
$array[] = "{$num}\t{$ligne}";
}
echo "Starting......: " . date("H:i:s") . " Postfix " . count($array) . " routings rules\n";
if (count($GLOBALS["transport_maps_AT"]) > 0) {
while (list($num, $ligne) = each($GLOBALS["transport_maps_AT"])) {
if ($ligne == null) {
continue;
}
$array[] = "{$num}\t{$ligne}";
}
}
if ($users->MAILMAN_INSTALLED) {
shell_exec("{$GLOBALS["postconf"]} -e \"mailman_destination_recipient_limit = 1\" >/dev/null 2>&1");
}
@file_put_contents("/etc/postfix/transport", implode("\n", $array));
shell_exec("{$GLOBALS["postmap"]} hash:/etc/postfix/transport >/dev/null 2>&1");
shell_exec("{$GLOBALS["postmap"]} hash:/etc/postfix/transport.throttle >/dev/null 2>&1");
shell_exec("{$GLOBALS["postconf"]} -e \"transport_maps = hash:/etc/postfix/transport.throttle, hash:/etc/postfix/transport, hash:/etc/postfix/transport.banned,hash:/etc/postfix/copy.transport\" >/dev/null 2>&1");
}