game/item_edit_data.php

34 lines
1.1 KiB
PHP
Raw Normal View History

2022-06-06 21:30:34 +00:00
<?php
2022-12-19 18:26:14 +00:00
# Admin Only Area
2022-06-06 21:30:34 +00:00
/*
<EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>.
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>, <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>, <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>, <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>, <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>, <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
*/
2022-12-19 18:26:14 +00:00
const GAME = true;
2022-06-06 21:30:34 +00:00
include('_incl_data/__config.php');
include('_incl_data/class/__db_connect.php');
2022-12-19 18:26:14 +00:00
$u = User::start();
2022-06-06 21:30:34 +00:00
2022-12-19 18:26:14 +00:00
if (!$u->info['admin']) {
header('location: https://new-combats.com/');
exit();
}
$itm = mysql_fetch_array(
mysql_query('SELECT * FROM `items_main_data` WHERE `items_id` = ' . (int)$_GET['edit_item_data'])
);
if (isset($itm['id'])) {
if (isset($_POST['newdata'])) {
mysql_query(
'UPDATE `items_main_data` SET `data` = "' . mysql_real_escape_string(
$_POST['newdata']
) . '" WHERE `id` = "' . mysql_real_escape_string($itm['id']) . '" LIMIT 1'
);
die('<script>window.close();</script>');
}
echo '<form method="post" action="item_edit_data.php?edit_item_data=' . $itm['items_id'] . '"><b><3E><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>: ' . $itm['items_id'] . '</b><br><textarea name="newdata" rows="20" cols="100">' . $itm['data'] . '</textarea><br><input type="submit" value="<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"></form>';
2022-06-06 21:30:34 +00:00
}