move final success message out of the view with the other messages

This commit is contained in:
Nicolas Roman 2019-07-30 17:24:17 +02:00
parent b60bd7a115
commit 0fdc6d0855
2 changed files with 10 additions and 5 deletions

View File

@ -191,9 +191,9 @@ if (isset($_POST['submit'])) {
if (empty($domainsNotIncluded)) {
$errorMessage = "Le certificat existant couvre déjà tous les domaines jusqu'au " . $validUntil . ".";
$noticeMessage = "Le certificat existant couvre déjà tous les domaines jusqu'au " . $validUntil . ".";
array_push($messages, ["type" => "notice", "content" => $errorMessage]);
array_push($messages, ["type" => "notice", "content" => $noticeMessage]);
break;
}
@ -212,9 +212,16 @@ if (isset($_POST['submit'])) {
}
array_push($messages, ["type" => "warning", "content" => $warningMessage]);
break;
}
$noticeMessage = "Votre certificat SSL a bien été installé !";
array_push($messages, ["type" => "notice", "content" => $noticeMessage]);
break;
}
}
include_once EVOADMIN_BASE . '../tpl/webadmin-letsencrypt.tpl.php';

View File

@ -33,7 +33,7 @@ if (!empty($messages)) {
}
}
} else {
if (isset($_POST["submit"])) {
if (!isset($_POST["submit"])) {
echo "<p>Les domaines suivants seront intégrés au certificat : </p>";
if (count($_SESSION['letsencrypt-domains']) > 0) {
echo '<p>';
@ -47,7 +47,5 @@ if (!empty($messages)) {
</form>
<?php
}
} else {
echo "Votre certificat SSL a bien été installé !";
}
}