Linux SRV-16 6.18.44-paas #1 SMP PREEMPT_DYNAMIC Thu Aug 13 10:08:12 UTC 2026 x86_64
/
srv
/
data
/
web
/
vhosts
/
www.volley92.asso.fr
/
htdocs
/
admin174
/
connected
/
pages
/
/srv/data/web/vhosts/www.volley92.asso.fr/htdocs/admin174/connected/pages/sous-menu-add.php
<?php include "functions/function.php"; $title = $menu = $ss_menu = null; if(!empty($_POST)){ $title = $_POST['title']; $menu = $_POST['menu']; if(!empty($title)){ $stmt=$db_client->prepare("INSERT INTO category(title,menu, created_at,updated_at,id_company) VALUES (?,?,NOW(),NOW(),?)"); // on prépare notre requête $stmt->execute(array($title,$menu,$conf_id_company)); header("Location: categorie"); }else { echo "<div class='alert alert-danger'><button type='button' class='close' data-dismiss='alert'>×</button>Le champs Titre et Contenu doivent être renseignés.</div>"; } } ?> <h1>Ajout d'un sous-menu</h1> <form role="form" method="post" action="#" enctype="multipart/form-data"> <div class="form-group"> <label for="title">Titre</label> <input id="title" class='form-control' type="text" name="title" value="<?=$title?>" autofocus> </div> <div class="form-group"> <input type="checkbox" class="form-check-input" id="menu" name="menu" value="1"> <label class="form-check-label" for="menu">Menu</label> </div> <div class="form-group"> <input type="checkbox" class="form-check-input" id="ss-menu" name="menu" value="2"> <label class="form-check-label" for="ss-menu">Sous-menu</label> </div> <hr> <div class='text-center'> <a href="actualites" class="btn btn-default" >Annuler</a> <button type='submit' name='submitAjout' class='btn btn-success'>Ajouter</button> </div> </form>