|
@@ -11,6 +11,7 @@ use ThurData\Servers\KerioEmail\Core\UI\Widget\Forms\Fields\InputGroupElements;
|
|
|
use ThurData\Servers\KerioEmail\Core\UI\Widget\Forms\Fields\Hidden;
|
|
use ThurData\Servers\KerioEmail\Core\UI\Widget\Forms\Fields\Hidden;
|
|
|
use ThurData\Servers\KerioEmail\Core\UI\Widget\Forms\Fields\Textarea;
|
|
use ThurData\Servers\KerioEmail\Core\UI\Widget\Forms\Fields\Textarea;
|
|
|
use ThurData\Servers\KerioEmail\Core\UI\Widget\Forms\Fields\Info;
|
|
use ThurData\Servers\KerioEmail\Core\UI\Widget\Forms\Fields\Info;
|
|
|
|
|
+use ThurData\Servers\KerioEmail\Core\Helper\DnsHelper;
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
*
|
|
*
|
|
@@ -29,6 +30,22 @@ class GeneralSection extends FreeFieldsSection
|
|
|
|
|
|
|
|
public function initContent()
|
|
public function initContent()
|
|
|
{
|
|
{
|
|
|
|
|
+ $maildomain = $this->getRequestValue('actionElementId');
|
|
|
|
|
+ $dns = new DnsHelper();
|
|
|
|
|
+
|
|
|
|
|
+ if($dns->selfDns($maildomain)) {
|
|
|
|
|
+ $infodns = new Info('infodns');
|
|
|
|
|
+ $infodns->setId('infodns');
|
|
|
|
|
+ $infodns->setName('infodns');
|
|
|
|
|
+ $infodns->setDescription('infodnsmessage');
|
|
|
|
|
+ $this->addField($infodns);
|
|
|
|
|
+ } else {
|
|
|
|
|
+ $infoextdns = new Info('infoextdns');
|
|
|
|
|
+ $infoextdns->setId('infoextdns');
|
|
|
|
|
+ $infoextdns->setName('infoextdns');
|
|
|
|
|
+ $infoextdns->setDescription('infoextdnsmessage');
|
|
|
|
|
+ $this->addField($infoextdns);
|
|
|
|
|
+ }
|
|
|
$mxthurdata = new Text('mxthurdata');
|
|
$mxthurdata = new Text('mxthurdata');
|
|
|
$mxthurdata->addHtmlAttribute('readonly','true');
|
|
$mxthurdata->addHtmlAttribute('readonly','true');
|
|
|
$mxthurdata->setDescription('description');
|
|
$mxthurdata->setDescription('description');
|