From cac207620d4c2c00663292a8b5c5f7d417d4fc12 Mon Sep 17 00:00:00 2001 From: "Igor Barkov (iwork)" Date: Tue, 23 Jun 2020 16:37:25 +0300 Subject: [PATCH] db fix --- chat.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/chat.php b/chat.php index 86b070a..bfac820 100644 --- a/chat.php +++ b/chat.php @@ -28,7 +28,7 @@ function show_messages() SELECT `msg`, `msgdate`, - (SELECT `login` FROM `users` WHERE `users`.`id` = `uid`) AS `from`, + (SELECT `login` FROM `users` WHERE `users`.`id` = `user_id`) AS `from`, `type` FROM `chat` ORDER BY `id` LIMIT 50'); while ($message = $chat->fetch_assoc()) {