Version 1.7b
This commit is contained in:
parent
58928889ed
commit
8a8280758b
716 changed files with 4361 additions and 33524 deletions
38
onyx/hb_game/jeu/admin/planete.php
Normal file
38
onyx/hb_game/jeu/admin/planete.php
Normal file
|
|
@ -0,0 +1,38 @@
|
|||
<?php
|
||||
if(!defined('INDEX')) { header('Location: ../'); exit; }
|
||||
$pagea = 'print';
|
||||
$titre = 'Vérification planète';
|
||||
|
||||
$template->assign('linkpage', 'vplanetes');
|
||||
|
||||
if (!empty($_GET['id']) && !empty($_GET['key']) && $_GET['key'] != 'id') {
|
||||
$pagea = 'print_key';
|
||||
$id_plan = $_GET['id'];
|
||||
$req = $chapeau->unique_query("SELECT * FROM `planete` WHERE `id` = '$id_plan';");
|
||||
$template->assign('tableau', $req);
|
||||
$req = $chapeau->unique_query("DESCRIBE `planete` `".$_GET['key']."`;");
|
||||
$template->assign('type', explode('(', $req['Type']));
|
||||
$template->assign('idPlan', $id_plan);
|
||||
$template->assign('key', $_GET['key']);
|
||||
}
|
||||
elseif (!empty($_GET['id'])) {
|
||||
$id_plan = $_GET['id'];
|
||||
if (isset($_POST['key']) && isset($_POST['mod'])) {
|
||||
$key = $_POST['key'];
|
||||
$mod = $_POST['mod'];
|
||||
$chapeau->escape($mod);
|
||||
$chapeau->query("UPDATE `planete` SET `$key` = '$mod' WHERE `id` = '$id_plan';");
|
||||
}
|
||||
$req = $chapeau->unique_query("SELECT * FROM `planete` WHERE `id` = '$id_plan';");
|
||||
$template->assign('tableau', $req);
|
||||
$template->assign('idPlan', $id_plan);
|
||||
}
|
||||
elseif (isset($_GET['amas']) && isset($_GET['ss']) && !empty($_GET['pos'])) {
|
||||
$req = $chapeau->unique_query("SELECT * FROM `planete` WHERE `galaxie` = '".$_GET['amas']."' AND `ss` = '".$_GET['ss']."' AND `position` = '".$_GET['pos']."';");
|
||||
header('Location: admin.php?p=vplanetes&id='.$req['id']);
|
||||
exit;
|
||||
}
|
||||
else {
|
||||
$pagea = 'print_choixP';
|
||||
}
|
||||
?>
|
||||
Loading…
Add table
Add a link
Reference in a new issue