Initial commit
Création de tous les dossiers et fichiers avec mise à part des constantes
This commit is contained in:
commit
4c71fb59b4
42 changed files with 2544 additions and 0 deletions
60
vues/vAjouterElement.php
Normal file
60
vues/vAjouterElement.php
Normal file
|
@ -0,0 +1,60 @@
|
|||
<section id="principal">
|
||||
<h2>Liste des ingrédients existants :</h2>
|
||||
<ul>
|
||||
<?php foreach($listeIngredient as $ingredient): ?>
|
||||
<li><a href="index.php?page=element&type=ingredient&id=<?=$ingredient[0]?>"><?=$ingredient[1]?></a> (<?=$ingredient[2]?>)</li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
|
||||
<?php if($_SESSION['auth']): ?>
|
||||
<p>Ajouter un ingrédient :</p>
|
||||
<form method="POST" action="index.php?page=ajouterElement">
|
||||
<label for="nomIngredient">Nom :</label>
|
||||
<input type="text" name="nomIngredient" pattern="<?=PATTERN_CHAMPS_NOM?>" title="<?=DESC_CHAMPS_NOM?>" required />
|
||||
<br/>
|
||||
<p>Disponibilité :</p>
|
||||
<?php foreach (lANNEE as $mois):?>
|
||||
·
|
||||
<input type="checkbox" name="<?=$mois?>" id="<?=$mois?>" checked="true"/>
|
||||
<label for="<?=$mois?>"><?=$mois?></label>
|
||||
<?php endforeach ?>
|
||||
·
|
||||
<br/>
|
||||
<input type="submit" value="Ajouter l'ingrédient"/>
|
||||
</form>
|
||||
<?php endif ?>
|
||||
|
||||
<h2>Liste des ustensiles existants :</h2>
|
||||
<ul>
|
||||
<?php foreach($listeUstensile as $ustensile): ?>
|
||||
<li><a href="index.php?page=element&type=ustensile&id=<?=$ustensile[1]?>"><?=$ustensile[0]?></a></li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
|
||||
<?php if($_SESSION['auth']): ?>
|
||||
<p>Ajouter un ustensile :</p>
|
||||
<form method="POST" action="index.php?page=ajouterElement">
|
||||
<label for="nomUstensile">Nom :</label>
|
||||
<input type="text" name="nomUstensile" pattern="<?=PATTERN_CHAMPS_NOM?>" title="<?=DESC_CHAMPS_NOM?>" required />
|
||||
<br/>
|
||||
<input type="submit" value="Ajouter l'ustensile"/>
|
||||
</form>
|
||||
<?php endif ?>
|
||||
|
||||
<h2>Liste des unités existantes :</h2>
|
||||
<ul>
|
||||
<?php foreach($listeUnite as $unite): ?>
|
||||
<li><a href="index.php?page=element&type=unite&id=<?=$unite[1]?>"><?=$unite[0]?></a></li>
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
|
||||
<?php if($_SESSION['auth']): ?>
|
||||
<p>Ajouter une unité :</p>
|
||||
<form method="POST" action="index.php?page=ajouterElement">
|
||||
<label for="nomUnite">Symbole :</label>
|
||||
<input type="text" name="nomUnite" required />
|
||||
<br/>
|
||||
<input type="submit" value="Ajouter l'unité"/>
|
||||
</form>
|
||||
<?php endif ?>
|
||||
</section>
|
Loading…
Add table
Add a link
Reference in a new issue