• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

View Character bug (website)

dunnish

New Member
Joined
Jun 18, 2009
Messages
277
Solutions
1
Reaction score
3
Hello OTland! :)
I have a little problem with my "Characters" on my web site. When I search on a character this error message comes up:

Code:
Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE[42S22]: Column not found: 1054 Unknown column 'time' in 'order clause'' in C:\xampp\htdocs\characters.php:199 Stack trace: #0 C:\xampp\htdocs\characters.php(199): PDO->query('SELECT * FROM p...') #1 C:\xampp\htdocs\index.php(93): include('C:\xampp\htdocs...') #2 {main} thrown in C:\xampp\htdocs\characters.php on line 199

And this is the script on line 199:

Code:
$player_deaths = $SQL->query('SELECT * FROM player_deaths WHERE '.$player->getId().' = player_id ORDER BY time DESC');

When I remove the script above it works, but I can't see the characters deaths. So I would appreciate some help on this!

Thanks in advance
Dunnish
 
PHP:
$player_deaths = $SQL->query('SELECT `id`, `date`, `level` FROM `player_deaths` WHERE `player_id` = '.$player->getId().' ORDER BY `date` DESC LIMIT 0,10;');
 
Back
Top