using DomainInputFormField for ServerName update field

This commit is contained in:
Nicolas Roman 2019-03-21 10:12:32 +01:00 committed by Ludovic Poujol
parent 7e02e50047
commit 20aeb60cda
2 changed files with 10 additions and 15 deletions

View file

@ -25,7 +25,7 @@ if (isset($_GET['edit']) ) {
include_once EVOADMIN_BASE . '../tpl/menu.tpl.php';
$form = new FormPage("Modification du ServerName", FALSE);
$form->addField('domain_servername', new TextInputFormField("Server Name", FALSE), $_GET['edit']);
$form->addField('domain_servername', new DomainInputFormField("ServerName", FALSE), $_GET['edit']);
if (!empty($_POST)) {
$form->isCurrentPage(TRUE);

View file

@ -13,7 +13,7 @@
?>
<h2>Server Name</h2>
<h2>ServerNames</h2>
<?php
@ -43,12 +43,7 @@
</table>
<?php
} else {
print "<p>Aucun alias existant pour le domaine $domain !</p>";
if (is_superadmin()) {
print "<center>";
printf('<p><a href="/webadmin/edit/%s?add">Ajouter un alias</a></p>', $domain);
print "</center>";
}
print "<p>Aucun ServerName existant pour le domaine $domain !</p>";
}