Changement d'adresse dynamique
This commit is contained in:
@@ -55,6 +55,13 @@ $noticeEnabled = recupererSetting('site_notice_enabled') ?? '1';
|
||||
// Valeur actuelle du captcha anti-robot (activé par défaut)
|
||||
$captchaEnabled = recupererSetting('captcha_enabled') ?? '1';
|
||||
|
||||
// Valeurs actuelles des coordonnées de la page contact
|
||||
$contactEmail = recupererSetting('contact_email') ?? 'esteban.moussu@ik.me';
|
||||
$contactEmailEnabled = recupererSetting('contact_email_enabled') ?? '1';
|
||||
$contactAddressLine1 = recupererSetting('contact_address_line1') ?? '20 Grande rue';
|
||||
$contactAddressLine2 = recupererSetting('contact_address_line2') ?? '52500 Broncourt';
|
||||
$contactAddressEnabled = recupererSetting('contact_address_enabled') ?? '1';
|
||||
|
||||
// Page du panneau d'administration
|
||||
?>
|
||||
|
||||
@@ -73,6 +80,7 @@ $captchaEnabled = recupererSetting('captcha_enabled') ?? '1';
|
||||
<a href="#admin-ecoles"><i class="fa-solid fa-graduation-cap"></i> Écoles</a>
|
||||
<a href="#admin-competences"><i class="fa-solid fa-code"></i> Compétences</a>
|
||||
<a href="#admin-logos"><i class="fa-solid fa-images"></i> Logos</a>
|
||||
<a href="#admin-contact"><i class="fa-solid fa-address-card"></i> Contact</a>
|
||||
<a href="#admin-notification"><i class="fa-solid fa-bell"></i> Notification</a>
|
||||
<a href="#admin-securite"><i class="fa-solid fa-shield-halved"></i> Sécurité</a>
|
||||
<a href="#admin-utilisateurs"><i class="fa-solid fa-users"></i> Utilisateurs</a>
|
||||
@@ -377,6 +385,45 @@ $captchaEnabled = recupererSetting('captcha_enabled') ?? '1';
|
||||
<?php afficherLogosAdmin(); ?>
|
||||
</section>
|
||||
|
||||
<!-- ========== SECTION CONTACT ========== -->
|
||||
<section id="admin-contact" class="admin-section">
|
||||
<h2 class="admin-section-title"><i class="fa-solid fa-address-card"></i> Coordonnées de contact</h2>
|
||||
|
||||
<div class="project-container">
|
||||
<div class="project-form-card">
|
||||
<!-- on envoie les données à updateSettings.php -->
|
||||
<form method="POST" action="../scripts/updateSettings.php">
|
||||
<input type="hidden" name="csrf_token" value="<?php echo htmlspecialchars(csrfToken()); ?>">
|
||||
<input type="hidden" name="settings_group" value="contact">
|
||||
|
||||
<label>Adresse email</label>
|
||||
<input type="email" name="contact_email" value="<?php echo htmlspecialchars($contactEmail); ?>">
|
||||
|
||||
<!-- Checkbox pour afficher / masquer l'email sur la page contact -->
|
||||
<label class="checkbox-row">
|
||||
<input type="checkbox" name="contact_email_enabled" value="1" <?php echo $contactEmailEnabled === '1' ? 'checked' : ''; ?>>
|
||||
Afficher l'email sur la page contact
|
||||
</label>
|
||||
|
||||
<label>Adresse postale - ligne 1 (rue)</label>
|
||||
<input type="text" name="contact_address_line1" value="<?php echo htmlspecialchars($contactAddressLine1); ?>">
|
||||
|
||||
<label>Adresse postale - ligne 2 (code postal / ville)</label>
|
||||
<input type="text" name="contact_address_line2" value="<?php echo htmlspecialchars($contactAddressLine2); ?>">
|
||||
|
||||
<!-- Checkbox pour afficher / masquer l'adresse postale sur la page contact -->
|
||||
<label class="checkbox-row">
|
||||
<input type="checkbox" name="contact_address_enabled" value="1" <?php echo $contactAddressEnabled === '1' ? 'checked' : ''; ?>>
|
||||
Afficher l'adresse postale sur la page contact
|
||||
</label>
|
||||
|
||||
<input type="submit" name="submitsettings" value="Enregistrer les coordonnées" class="btn-submit">
|
||||
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<!-- ========== SECTION NOTIFICATION ========== -->
|
||||
<section id="admin-notification" class="admin-section">
|
||||
<h2 class="admin-section-title"><i class="fa-solid fa-bell"></i> Notification de la page d'accueil</h2>
|
||||
|
||||
Reference in New Issue
Block a user