Quote:
"SELECT * FROM " . TABLE_PREFIX . "user WHERE userid = '$bbuserinfo[userid]'"
"SELECT * FROM " . TABLE_PREFIX . "user WHERE userid = $bbuserinfo[userid]"
"SELECT * FROM " . TABLE_PREFIX . "user WHERE userid = ".$bbuserinfo['userid']
|
I'd say, the one that takes the least space.
However, every one of these would do, even though I personally prefer the first and second ways of doing it. They are neater than the third one. The third way of doing it often ends up in parse error because you accidentally forgot to put a closing ' " ', or because you put an extra concatenation symbol...
It doesn't have to be so sophisticated... All the three ways would count as the right ways to do it.
Quote:
you shouldn't encapulate numbers but at the same time
SQL Query: (how to run queries)
"SELECT * FROM " . TABLE_PREFIX . "user WHERE userid = " . intval($bbuserinfo[userid]) . ""
would probably be the stardard set for a gold-star according to this thread
|
This is an intended exaggeration... Why do you imply that I would intval() something that is already an integer???
Quote:
my bad you just said you weren't the idea leader thus that really held no weight, unless i decided so, ok bu
|
Shut the f*ck up and stop trying to say that I said what I didn't say. Thanks.