Надеюсь рабочая гравировка. Размечтался 2. :(

This commit is contained in:
Igor Barkov [iwork] 2018-12-12 19:22:26 +02:00
parent 0a861d3bbe
commit 919ea2957c

View File

@ -15,7 +15,7 @@ if ($user['battle'] != 0) {
// Гравировка 30 кред. Максимум 32 символа.
if (input::post('gravirovka_text') AND input::post('itemId') AND ($user['money'] >= 30)) {
if (33 > iconv_strlen(input::post('gravirovka_text'))) {
db::c()->query('UPDATE `inventory` SET `text` = "?s" WHERE `dressed` = 0 AND `setsale` = 0 AND `owner` = ?i AND `id` = ?i', input::post('count'), $_SESSION['uid'], input::post('set'));
db::c()->query('UPDATE `inventory` SET `text` = "?s" WHERE `dressed` = 0 AND `setsale` = 0 AND `owner` = ?i AND `id` = ?i', input::post('gravirovka_text'), $_SESSION['uid'], input::post('itemId'));
db::c()->query('UPDATE `users` SET `money` = `money` - 30 WHERE `id` = ?i', $_SESSION['uid']);
$status = 'Гравировка добавлена!';
} else $status = 'Превышен лимит в 32 символа!';