root / admin / admin.php @ a7b49c8fba1b5566d116880d3799cde128013f70
Historique | Voir | Annoter | Télécharger (18,1 ko)
1 | <?php
|
---|---|
2 | /*
|
3 | * admin.php - Administration des compétitions |
4 | * Copyright (C) 2008 Romuald DELAVERGNE <delavergne@free.fr> |
5 | * |
6 | * This source code is licensed under the GNU General Public License, |
7 | * Version 2. See the file COPYING for more details. |
8 | */ |
9 | |
10 | require_once 'zip.lib.php'; |
11 | require_once 'unzip.lib.php'; |
12 | |
13 | if (basename(dirname($_SERVER['PHP_SELF'])) == "admin") |
14 | require_once '../functions.php'; |
15 | else
|
16 | require_once 'functions.php'; |
17 | |
18 | function hiddenVars() { ?> |
19 | <input type="hidden" name="typeCompetition" value="<?=$_POST['typeCompetition']?>" /> |
20 | <input type="hidden" name="saison" value="<?=$_POST['saison']?>" /> |
21 | <input type="hidden" name="div1" value="<?=$_POST['div1']?>" /> |
22 | <input type="hidden" name="div2" value="<?=$_POST['div2']?>" /> |
23 | <input type="hidden" name="poule" value="<?=$_POST['poule']?>" /> |
24 | <input type="hidden" name="phase" value="<?=$_POST['phase']?>" /> |
25 | <?php }
|
26 | |
27 | function retour($button, $message = "") { ?>
|
28 | <form method="post" action="index.php"> |
29 | <?php if ($message != "") echo "\t\t\t$message"; ?> |
30 | <?php hiddenVars() ?> |
31 | <input type="submit" value="<?=$button?>" /> |
32 | </form>
|
33 | <?php }
|
34 | |
35 | /* |
36 | echo "<pre>\n";
|
37 | print_r($_POST); |
38 | echo "</pre>\n";
|
39 | */ |
40 | |
41 | // Données reçues par l'index ou cette page |
42 | $championnat = $_POST['championnat']; |
43 | if ($_POST['validation_championnat'] == "ajouter") $championnat = "validation_ajouter"; |
44 | if ($_POST['validation_championnat'] == "modifier") $championnat = "validation_modifier"; |
45 | if ($_POST['validation_penalites'] == "valider") $championnat = "validation_penalites"; |
46 | if ($_POST['validation_ajustements'] == "valider") $championnat = "validation_ajustements"; |
47 | |
48 | if (isset($_POST['rencontre-ajouter'])) { |
49 | $rencontre = "ajouter"; |
50 | } else { |
51 | $vars = preg_grep("/^rencontre-/", array_keys($_POST)); |
52 | if ($vars) { |
53 | $rencontre = $_POST[current($vars)]; |
54 | $rencontreId = current($vars); |
55 | } |
56 | } |
57 | { |
58 | $vars = preg_grep("/^adjust-/", array_keys($_POST)); |
59 | if ($vars) { |
60 | $championnat = "validation_ajustement"; |
61 | switch ($_POST[current($vars)]) { |
62 | case '↑':
|
63 | $action = "up"; |
64 | break; |
65 | case '↓':
|
66 | $action = "down"; |
67 | break; |
68 | default: |
69 | $action = "unknown"; |
70 | break; |
71 | } |
72 | list($prefix, $equipe) = explode("-", current($vars)); |
73 | } |
74 | } |
75 | if ($_POST['validation_rencontre'] == "ajouter") $rencontre = "validation_ajouter"; |
76 | if ($_POST['validation_rencontre'] == "modifier") $rencontre = "validation_modifier"; |
77 | |
78 | $equipes = get_magic_quotes_gpc() ? stripslashes($_POST['equipes']) : $_POST['equipes']; |
79 | $journees = get_magic_quotes_gpc() ? stripslashes($_POST['journees']) : $_POST['journees']; |
80 | $journee = get_magic_quotes_gpc() ? stripslashes($_POST['journee']) : $_POST['journee']; |
81 | $domicile = get_magic_quotes_gpc() ? stripslashes($_POST['domicile']) : $_POST['domicile']; |
82 | $visiteur = get_magic_quotes_gpc() ? stripslashes($_POST['visiteur']) : $_POST['visiteur']; |
83 | $ptsDom = get_magic_quotes_gpc() ? stripslashes($_POST['ptsDom']) : $_POST['ptsDom']; |
84 | $ptsVis = get_magic_quotes_gpc() ? stripslashes($_POST['ptsVis']) : $_POST['ptsVis']; |
85 | $scoreDom = get_magic_quotes_gpc() ? stripslashes($_POST['scoreDom']) : $_POST['scoreDom']; |
86 | $scoreVis = get_magic_quotes_gpc() ? stripslashes($_POST['scoreVis']) : $_POST['scoreVis']; |
87 | $fftDom = get_magic_quotes_gpc() ? stripslashes($_POST['fftDom']) : $_POST['fftDom']; |
88 | $fftVis = get_magic_quotes_gpc() ? stripslashes($_POST['fftVis']) : $_POST['fftVis']; |
89 | |
90 | $message = ""; |
91 | |
92 | if ($_POST['saison'] && $_POST['div1']) { |
93 | $path = (IamAdmin()) ? "../datas" : "datas"; |
94 | $path .= "/".$_POST['saison']."/".$_POST['div1']; |
95 | if ($_POST['div2'] != "") $path .= $SEP_DIV.$_POST['div2']; |
96 | if ($_POST['poule'] != "" || $_POST['phase'] != "") $path .= "/"; |
97 | if ($_POST['poule'] != "") $path .= $_POST['poule']; |
98 | if ($_POST['phase'] != "") $path .= $SEP_DIV.$_POST['phase']; |
99 | } |
100 | |
101 | if ($_POST['exporter'] == "exporter") { |
102 | $zip = new zipfile(); |
103 | backup($zip, "../datas", "datas"); |
104 | $archive = $zip->file();
|
105 | header("Content-Type: application/x-zip"); |
106 | header("Content-Disposition: inline; filename=datas-".date("Y-m-d").".zip"); |
107 | echo $archive; |
108 | exit; |
109 | } elseif ($_POST['validation_importer'] == "importer") { |
110 | if ($_FILES['zipfile']['error'] == 0) { |
111 | $dest = ".."; |
112 | $zip = new SimpleUnzip($_FILES['zipfile']['tmp_name']); |
113 | if ($zip) { |
114 | $needToImport = array(); |
115 | $alreadyExist = array(); |
116 | foreach ($zip->Entries as $extr) {
|
117 | if (!file_exists($dest."/".$extr->Path)) {
|
118 | mkdirRecursive($dest."/".$extr->Path);
|
119 | $needToImport[] = $extr->Path;
|
120 | } else { |
121 | if (!in_array($extr->Path, $needToImport)) {
|
122 | if (!in_array($extr->Path, $alreadyExist)) {
|
123 | $message .= "<p>Le championnat ".$extr->Path." n'a pas été importé car il existe déjà !</p>"; |
124 | $alreadyExist[] = $extr->Path;
|
125 | } |
126 | } |
127 | } |
128 | if (in_array($extr->Path, $needToImport)) {
|
129 | $fh = fopen($dest."/".$extr->Path."/".$extr->Name, 'w'); |
130 | fwrite($fh, $extr->Data);
|
131 | fclose($fh); |
132 | } |
133 | } |
134 | $message .= "Données importées"; |
135 | } else { |
136 | $message = $_POST['zipfile'].": fichier invalide !"; |
137 | } |
138 | } else { |
139 | $message = "Erreur lors du chargement du fichier '".$_FILES['zipfile']['name']."' !"; |
140 | } |
141 | } elseif ($_POST['supprimer-tout'] == "tout supprimer") { |
142 | $message = "pas implémenté."; |
143 | } |
144 | |
145 | if ($path) { |
146 | //echo "<p>path=$path.</p>\n"; |
147 | switch ($championnat) { |
148 | case "pénalités": |
149 | $Pen = getPenalites($path); |
150 | $equipes = getEquipes($path); |
151 | break; |
152 | case "ajustements": |
153 | $Adjust = getAjustements($path); |
154 | $equipes = getEquipes($path); |
155 | break; |
156 | case "modifier": |
157 | if (file_exists("$path/equipes")) { |
158 | $equipes = file_get_contents("$path/equipes"); |
159 | } |
160 | if (file_exists("$path/journees")) { |
161 | $journees = file_get_contents("$path/journees"); |
162 | } |
163 | break; |
164 | case "validation_ajouter": |
165 | if (!file_exists($path)) { |
166 | mkdirRecursive($path); |
167 | my_file_put_contents("$path/equipes", $equipes); |
168 | my_file_put_contents("$path/journees", $journees); |
169 | $message = "La compétition a été ajoutée."; |
170 | } else { |
171 | $message = "La compétition existe déjà !"; |
172 | } |
173 | break; |
174 | case "validation_modifier": |
175 | my_file_put_contents("$path/equipes", $equipes); |
176 | my_file_put_contents("$path/journees", $journees); |
177 | $message = "La compétition a été mise à jour."; |
178 | break; |
179 | case "validation_penalites": |
180 | $vars = preg_grep("/^pen_/", array_keys($_POST)); |
181 | if ($vars) { |
182 | $penalites = ""; |
183 | foreach ($vars as $var) { |
184 | if ($_POST[$var] > 0) {
|
185 | list($prefix, $equipe) = explode("_", $var); |
186 | $penalites .= $equipe.":".$_POST[$var]."\n"; |
187 | } |
188 | } |
189 | $file = "$path/penalites"; |
190 | if ($penalites) { |
191 | my_file_put_contents($file, $penalites); |
192 | } else { |
193 | if (file_exists($file)) unlink($file); |
194 | } |
195 | $message = "Les pénalités ont été mises à jour."; |
196 | } |
197 | break; |
198 | case "validation_ajustements": |
199 | $vars = preg_grep("/^adjust_/", array_keys($_POST)); |
200 | if ($vars) { |
201 | $ajustements = ""; |
202 | foreach ($vars as $var) { |
203 | if ($_POST[$var] != 0) { |
204 | if (abs($_POST[$var]) <= 9) {
|
205 | list($prefix, $equipe) = explode("_", $var); |
206 | $ajustements .= $equipe.":".$_POST[$var]."\n"; |
207 | } else { |
208 | $message = "Ajustement trop important (".$_POST[$var].")."; |
209 | break 2; |
210 | } |
211 | } |
212 | } |
213 | $file = "$path/ajustements"; |
214 | if ($ajustements) { |
215 | my_file_put_contents($file, $ajustements); |
216 | } else { |
217 | if (file_exists($file)) unlink($file); |
218 | } |
219 | $message = "Les ajustements ont été mis à jour."; |
220 | } |
221 | break; |
222 | case "validation_ajustement": |
223 | $Adjust = getAjustements($path); |
224 | $equipes = getEquipes($path); |
225 | switch ($action) { |
226 | case "up": |
227 | $Adjust[$equipe]++; |
228 | $message = "L'équipe ".$equipes[$equipe]." a été remontée d'une position."; |
229 | break; |
230 | case "down": |
231 | $Adjust[$equipe] = $Adjust[$equipe] - 1; /* $var-- don't works with empty value */ |
232 | $message = "L'équipe ".$equipes[$equipe]." a été redescendue d'une position."; |
233 | break; |
234 | default: |
235 | break 2; |
236 | } |
237 | $ajustements = ""; |
238 | foreach ($Adjust as $n => $val) {
|
239 | if ($val != 0) { |
240 | if (abs($val) <= 9) {
|
241 | $ajustements .= "$n:$val\n"; |
242 | } else { |
243 | $message = "Ajustement trop important ($val)."; |
244 | break 2; |
245 | } |
246 | } |
247 | } |
248 | $file = "$path/ajustements"; |
249 | if ($ajustements) { |
250 | my_file_put_contents($file, $ajustements); |
251 | } else { |
252 | if (file_exists($file)) unlink($file); |
253 | } |
254 | break; |
255 | case "supprimer": |
256 | // Suppression de tous les fichiers du répertoire |
257 | if ($dir = opendir($path)) { |
258 | while (($file = readdir($dir)) !== FALSE) { |
259 | if (is_file("$path/$file")) unlink("$path/$file"); |
260 | } |
261 | closedir($dir); |
262 | } |
263 | // Suppression du maximum de répertoires |
264 | while (isEmptyDir($path) && basename($path) != "datas") { |
265 | monRmdir($path); |
266 | $path = dirname($path); |
267 | } |
268 | $message = "Le championnat a été supprimé."; |
269 | break; |
270 | } |
271 | switch ($rencontre) { |
272 | case "ajouter": |
273 | $equipes = getEquipes($path); |
274 | $journees = getJournees($path); |
275 | break; |
276 | case "modifier": |
277 | $equipes = getEquipes($path); |
278 | $journees = getJournees($path); |
279 | list($prefix, $journee, $domicile, $visiteur) = explode("-", $rencontreId); |
280 | $file = "$path/match-".$journee."-".$domicile."-".$visiteur; |
281 | if (file_exists($file)) { |
282 | $resu = file_get_contents($file); |
283 | list($ptsDom, $ptsVis, $scoreDom, $scoreVis, $fftDom, $fftVis) = explode(":", $resu); |
284 | } |
285 | break; |
286 | case "validation_ajouter": |
287 | if ($journee == "" || $domicile == "" || $visiteur == "") { |
288 | $message = "Vous devez saisir le numéro de la journée, l'équipe qui reçoit et qui se déplace !"; |
289 | } else { |
290 | $file = "$path/match-".$journee."-".$domicile."-".$visiteur; |
291 | if (!file_exists($file)) { |
292 | my_file_put_contents($file, $ptsDom.":".$ptsVis.":".$scoreDom.":".$scoreVis.":".$fftDom.":".$fftVis); |
293 | $message = "La nouvelle rencontre a été ajoutée."; |
294 | } else { |
295 | $message = "La rencontre existe déjà !"; |
296 | } |
297 | } |
298 | break; |
299 | case "validation_modifier": |
300 | $file = "$path/match-".$journee."-".$domicile."-".$visiteur; |
301 | my_file_put_contents($file, $ptsDom.":".$ptsVis.":".$scoreDom.":".$scoreVis.":".$fftDom.":".$fftVis); |
302 | $message = "La rencontre a été mise à jour."; |
303 | break; |
304 | case "supprimer": |
305 | list($prefix, $journee, $domicile, $visiteur) = explode("-", $rencontreId); |
306 | $file = "match-".$journee."-".$domicile."-".$visiteur; |
307 | if (file_exists("$path/$file")) { |
308 | unlink("$path/$file"); |
309 | $message = "La rencontre a été supprimée."; |
310 | } |
311 | break; |
312 | } |
313 | } |
314 | ?>
|
315 | <html>
|
316 | <head>
|
317 | <title>Administration</title> |
318 | <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> |
319 | <meta http-equiv="Content-language" content="fr" /> |
320 | <meta name="copyright" content="Tous droits réservés - All Rights Reserved" /> |
321 | <meta name="author" content="Romuald DELAVERGNE"> |
322 | </head>
|
323 | <html>
|
324 | <body>
|
325 | <?php if ($championnat == "ajouter" || $championnat == "modifier" ) { ?> |
326 | <form name="admin" method="post" action="<?=$_SERVER['PHP_SELF']?>"> |
327 | <table border="0"> |
328 | <tr>
|
329 | <td>Saison</td> |
330 | <td>
|
331 | : |
332 | <?php if ($championnat == "ajouter") { ?> |
333 | <input type="text" name="saison" size="5" value="" /> |
334 | <?php } else { ?> |
335 | <input type="hidden" name="saison" value="<?=$_POST['saison']?>" /> |
336 | <?=$_POST['saison']."/".($_POST['saison']+1)."\n"?> |
337 | <?php } ?> |
338 | </td>
|
339 | </tr>
|
340 | <?php if ($_POST['typeCompetition'] != "") { ?> |
341 | <input type="hidden" name="div1" value="<?=$_POST['typeCompetition']?>" /> |
342 | <tr>
|
343 | <td><?=$_POST['typeCompetition'] == "C" ? "Coupe" : "Tournoi"?></td> |
344 | <td>
|
345 | : |
346 | <?php if ($championnat == "ajouter") { ?> |
347 | <input type="text" name="div2" value="" /> |
348 | <?php } else { ?> |
349 | <input type="hidden" name="div2" value="<?=$_POST['div2']?>" /> |
350 | <?=$_POST['div2']."\n"?> |
351 | <?php } ?> |
352 | </td>
|
353 | </tr>
|
354 | <?php } else { ?> |
355 | <tr>
|
356 | <td>Division</td> |
357 | <td>
|
358 | : |
359 | <?php if ($championnat == "ajouter") { ?> |
360 | <select name="div1"> |
361 | <option value=""></option> |
362 | <?php
|
363 | foreach ($DIVISION as $n => $d) { |
364 | echo "\t\t\t\t\t\t<option value=\"$n\">$d</option>\n"; |
365 | } |
366 | ?>
|
367 | </select>
|
368 | <input type="text" name="div2" size="3" value="" /> |
369 | <?php } else { ?> |
370 | <input type="hidden" name="div1" value="<?=$_POST['div1']?>" /> |
371 | <input type="hidden" name="div2" value="<?=$_POST['div2']?>" /> |
372 | <?=$_POST['div1'].$_POST['div2']."\n"?> |
373 | <?php } ?> |
374 | </td>
|
375 | </tr>
|
376 | <?php } ?> |
377 | <?php if ($championnat == "ajouter" || $_POST['poule']) { ?> |
378 | <tr>
|
379 | <td><?=($_POST['typeCompetition'] != "") ? "Poule/Tableau" : "Poule"?></td> |
380 | <td>
|
381 | : |
382 | <?php if ($championnat == "ajouter") { ?> |
383 | <input type="text" name="poule" value="" /> |
384 | <?php } else { ?> |
385 | <input type="hidden" name="poule" value="<?=$_POST['poule']?>" /> |
386 | <?=$_POST['poule']."\n"?> |
387 | <?php } ?> |
388 | </td>
|
389 | </tr>
|
390 | <?php } ?> |
391 | <?php if (($championnat == "ajouter" || $_POST['phase']) && $_POST['typeCompetition'] == "") { ?> |
392 | <tr>
|
393 | <td>Phase</td> |
394 | <td>
|
395 | : |
396 | <?php if ($championnat == "ajouter") { ?> |
397 | <select name="phase"> |
398 | <option value=""></option> |
399 | <option value="1">1</option> |
400 | <option value="2">2</option> |
401 | </select>
|
402 | <?php } else { ?> |
403 | <input type="hidden" name="phase" value="<?=$_POST['phase']?>" /> |
404 | <?=$_POST['phase']."\n"?> |
405 | <?php } ?> |
406 | </td>
|
407 | </tr>
|
408 | <?php } ?> |
409 | <tr>
|
410 | <td colspan="2"> |
411 | <br /> |
412 | Liste des <?=$_POST['typeCompetition'] == "T" ? "joueurs" : "équipes"?> : |
413 | </td>
|
414 | </tr>
|
415 | <tr>
|
416 | <td colspan="2"> |
417 | <textarea name="equipes" cols="30" rows="10"><?=$equipes?></textarea> |
418 | </td>
|
419 | </tr>
|
420 | <tr>
|
421 | <td colspan="2"> |
422 | <br /> |
423 | Liste des <?=$_POST['typeCompetition'] == "T" ? "tours" : "journées"?> : |
424 | </td>
|
425 | </tr>
|
426 | <tr>
|
427 | <td colspan="2"> |
428 | <textarea name="journees" cols="30" rows="10"><?=$journees?></textarea> |
429 | </td>
|
430 | </tr>
|
431 | </table>
|
432 | <?php if ($championnat == "ajouter") { ?> |
433 | <input type="submit" name="validation_championnat" value="ajouter" /> |
434 | <?php } ?> |
435 | <?php if ($championnat == "modifier" ) { ?> |
436 | <input type="submit" name="validation_championnat" value="modifier" /> |
437 | <?php } ?> |
438 | </form>
|
439 | <?php retour("annuler"); ?> |
440 | <?php } else if ($championnat == "pénalités") { ?> |
441 | <form method="post" action="<?=$_SERVER['PHP_SELF']?>"> |
442 | <table>
|
443 | <?php foreach ($equipes as $n => $e) { ?> |
444 | <tr>
|
445 | <td><?=$e?></td> |
446 | <td>:<input type="text" name="pen_<?=$n?>" size="3" value="<?=($Pen[$n] ? $Pen[$n] : "0")?>" /></td> |
447 | </tr>
|
448 | <?php } ?> |
449 | </table>
|
450 | <?php hiddenVars() ?> |
451 | <input type="submit" name="validation_penalites" value="valider" /> |
452 | </form>
|
453 | <?php retour("annuler"); ?> |
454 | <?php } else if ($championnat == "ajustements") { ?> |
455 | <form method="post" action="<?=$_SERVER['PHP_SELF']?>"> |
456 | <table>
|
457 | <?php foreach ($equipes as $n => $e) { ?> |
458 | <tr>
|
459 | <td><?=$e?></td> |
460 | <td>:<input type="text" name="adjust_<?=$n?>" size="3" value="<?=($Adjust[$n] ? $Adjust[$n] : "0")?>" /></td> |
461 | </tr>
|
462 | <?php } ?> |
463 | </table>
|
464 | <?php hiddenVars() ?> |
465 | <input type="submit" name="validation_ajustements" value="valider" /> |
466 | </form>
|
467 | <?php retour("annuler"); ?> |
468 | <?php } else if ($rencontre == "ajouter" || $rencontre == "modifier") { ?> |
469 | <form method="post" action="<?=$_SERVER['PHP_SELF']?>"> |
470 | <table border="0"> |
471 | <tr>
|
472 | <td colspan="4"> |
473 | <?php if ($rencontre == "ajouter") { ?> |
474 | <?=$_POST['typeCompetition'] == "" ? "Journée" : "Tour"?> : |
475 | <select name="journee"> |
476 | <option value=""></option> |
477 | <?php
|
478 | foreach ($journees as $n => $j) { |
479 | echo "\t\t\t\t\t\t<option value=\"$n\">$j</option>\n"; |
480 | } |
481 | ?>
|
482 | </select>
|
483 | <?php } else { ?> |
484 | <?=$journees[$journee]."\n"?> |
485 | <input type="hidden" name="journee" value="<?=$journee?>" /> |
486 | <?php } ?> |
487 | </td>
|
488 | </tr>
|
489 | <tr>
|
490 | <td>
|
491 | <?php if ($rencontre == "ajouter") { ?> |
492 | <?=$_POST['typeCompetition'] == "T" ? "Joueur 1" : "Équipe à domicile"?> : |
493 | <select name="domicile"> |
494 | <option value=""></option> |
495 | <?php
|
496 | foreach ($equipes as $n => $e) { |
497 | echo "\t\t\t\t\t\t<option value=\"$n\">$e</option>\n"; |
498 | } |
499 | ?>
|
500 | </select>
|
501 | <?php } else { ?> |
502 | <input type="hidden" name="domicile" value="<?=$domicile?>" /> |
503 | <?=$equipes[$domicile]."\n"?> |
504 | <?php } ?> |
505 | </td>
|
506 | <td> points : <input type="text" name="ptsDom" size="3" value="<?=$ptsDom?>" /></td> |
507 | <td> score : <input type="text" name="scoreDom" size="3" value="<?=$scoreDom?>" /></td> |
508 | <td>
|
509 | <label for="fftDom">forfait :</label> |
510 | <input type="checkbox" id="fftDom" name="fftDom"<?=$fftDom ? " checked" : ""?> /> |
511 | </td>
|
512 | </tr>
|
513 | <tr>
|
514 | <td>
|
515 | <?php if ($rencontre == "ajouter") { ?> |
516 | <?=$_POST['typeCompetition'] == "T" ? "Joueur 2" : "Équipe à l'extérieure"?> : |
517 | <select name="visiteur"> |
518 | <option value=""></option> |
519 | <?php
|
520 | foreach ($equipes as $n => $e) { |
521 | echo "\t\t\t\t\t\t<option value=\"$n\">$e</option>\n"; |
522 | } |
523 | ?>
|
524 | </select>
|
525 | <?php } else { ?> |
526 | <input type="hidden" name="visiteur" value="<?=$visiteur?>" /> |
527 | <?=$equipes[$visiteur]."\n"?> |
528 | <?php } ?> |
529 | </td>
|
530 | <td> points : <input type="text" name="ptsVis" size="3" value="<?=$ptsVis?>" /></td> |
531 | <td> score : <input type="text" name="scoreVis" size="3" value="<?=$scoreVis?>" /></td> |
532 | <td>
|
533 | <label for="fftVis">forfait :</label> |
534 | <input type="checkbox" id="fftVis" name="fftVis"<?=$fftVis ? " checked" : ""?> /> |
535 | </td>
|
536 | </tr>
|
537 | </table>
|
538 | <?php hiddenVars() ?> |
539 | <?php if ($rencontre == "ajouter") { ?> |
540 | <input type="submit" name="validation_rencontre" value="ajouter" /> |
541 | <?php } ?> |
542 | <?php if ($rencontre == "modifier") { ?> |
543 | <input type="submit" name="validation_rencontre" value="modifier" /> |
544 | <?php } ?> |
545 | </form>
|
546 | <?php retour("annuler"); ?> |
547 | <?php } else if ($_POST['importer'] == "importer") { ?> |
548 | <form method="post" enctype="multipart/form-data"> |
549 | <?php hiddenVars() ?> |
550 | <input type="file" name="zipfile" value="" /> |
551 | <input type="submit" name="validation_importer" value="importer" /> |
552 | </form>
|
553 | <?php retour("annuler"); ?> |
554 | <?php
|
555 | } else { |
556 | retour("continuer", $message); |
557 | } |
558 | ?>
|
559 | </body>
|
560 | </html>
|