You've already forked postfixadmin
mirror of
https://github.com/postfixadmin/postfixadmin.git
synced 2025-08-06 06:42:37 +03:00
token refactoring
This commit is contained in:
@@ -192,7 +192,7 @@ function check_language($use_post = true)
|
|||||||
// Failing that, is there a $_COOKIE['lang'] ?
|
// Failing that, is there a $_COOKIE['lang'] ?
|
||||||
if (safecookie('lang')) {
|
if (safecookie('lang')) {
|
||||||
$lang = safecookie('lang');
|
$lang = safecookie('lang');
|
||||||
if (is_string($lang) && array_key_exists($lang, $supported_languages)) {
|
if (!empty($lang) && array_key_exists($lang, $supported_languages)) {
|
||||||
return $lang;
|
return $lang;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -261,12 +261,8 @@ function check_domain($domain)
|
|||||||
if (function_exists('checkdnsrr')) {
|
if (function_exists('checkdnsrr')) {
|
||||||
$start = microtime(true); # check for slow nameservers, part 1
|
$start = microtime(true); # check for slow nameservers, part 1
|
||||||
|
|
||||||
// AAAA (IPv6) is only available in PHP v. >= 5
|
// Check for AAAA (IPv6), A, MX, or NS records
|
||||||
if (version_compare(phpversion(), "5.0.0", ">=") && checkdnsrr($domain, 'AAAA')) {
|
if (checkdnsrr($domain, 'AAAA') || checkdnsrr($domain, 'A') || checkdnsrr($domain, 'MX')) {
|
||||||
$retval = '';
|
|
||||||
} elseif (checkdnsrr($domain, 'A')) {
|
|
||||||
$retval = '';
|
|
||||||
} elseif (checkdnsrr($domain, 'MX')) {
|
|
||||||
$retval = '';
|
$retval = '';
|
||||||
} elseif (checkdnsrr($domain, 'NS')) {
|
} elseif (checkdnsrr($domain, 'NS')) {
|
||||||
error_log("DNS is not correctly configured for $domain to send or receive email");
|
error_log("DNS is not correctly configured for $domain to send or receive email");
|
||||||
|
Reference in New Issue
Block a user