Page 1 of 1
Needing A helping hand :)
Posted: Mon Mar 10, 2008 7:46 pm
by chips
all I would like to know is:
Code: Select all
" . DB_PREFIX . "users WHERE user_id=" . [color=#FF0000]$user_id[/color] $item_details['owner_id']);
How could I put
$user_id in there without getting an error?
Thanks.
Re: Needing A helping hand :)
Posted: Mon Mar 10, 2008 8:31 pm
by chips
anyone?
Re: Needing A helping hand :)
Posted: Mon Mar 10, 2008 9:47 pm
by Christopher
I could guess a . or , depending on whatever the heck is going on around in that code sub-snippet. What should the SQL statement look like? Are they parameters in a function call?
Re: Needing A helping hand :)
Posted: Tue Mar 11, 2008 6:40 am
by Rovas
From the sample you given: instead of:
chips wrote:all I would like to know is:
Code: Select all
" . DB_PREFIX . "users WHERE user_id=" . [color=#FF0000]$user_id[/color] $item_details['owner_id']);
use
Code: Select all
. DB_PREFIX . "users WHERE user_id=" .[color=#FF0000]$user_id[/color] ." AND [i]column name[/i]=" .$item_details['owner_id']);