Query Help

Blasteh

big tits
Apr 3, 2013
1,156
521
I'm working with BrainCMS, and I've been getting this weird error for some reason, the friends used to display, but now they don't for some reason. I tried most things, but for some reason I cannot get to the bottom of this – then again, I'm not really a stable developer.

You must be registered for see images attach


Home.php:
 

Kodys

lmao
Oct 24, 2016
36
17
I'm sure the problem is with this query
PHP:
$getUserData = DB::Fetch(DB::Query("SELECT * FROM users WHERE id = '".filter(DB::Escape($id."'"))));
Try replacing it with this query..?
PHP:
$getUserData = DB::Fetch(DB::Query("SELECT * FROM users WHERE id = ".filter(DB::Escape($id))));


Alternatively you could split it up so it's easier to understand
PHP:
$querryyy = DB::Query("SELECT * FROM users WHERE id = ".filter(DB::Escape($id)));
$getUserData = DB::Fetch($querryyy);
 

Blasteh

big tits
Apr 3, 2013
1,156
521
I'm sure the problem is with this query
PHP:
$getUserData = DB::Fetch(DB::Query("SELECT * FROM users WHERE id = '".filter(DB::Escape($id."'"))));
Try replacing it with this query..?
PHP:
$getUserData = DB::Fetch(DB::Query("SELECT * FROM users WHERE id = ".filter(DB::Escape($id))));
Wow, that one I didn't even look at. Thank you @Kodys, appreciated.
 

Users who are viewing this thread

Top