Add support for international domain names. Note that this relies on php-intl to be installed

Signed-off-by: DL6ER <dl6er@dl6er.de>
This commit is contained in:
DL6ER
2020-01-12 13:33:05 +01:00
parent 5eadd346b9
commit 65be9d89ef
4 changed files with 33 additions and 15 deletions

View File

@@ -30,6 +30,13 @@ function getTableContent($type) {
while($results !== false && $res = $results->fetchArray(SQLITE3_ASSOC))
{
$utf8_domain = idn_to_utf8($res['domain']);
// Convert domain name to international form
// if applicable
if($res['domain'] !== $utf8_domain)
{
$res['domain'] = $utf8_domain.' ('.$res['domain'].')';
}
array_push($entries, $res);
}