Re: Turning result into array from columns
| From: | Dave W | Date: | Sat, 23 Sep 2006 13:08:48 +0000 |
| Subject: | Re: Turning result into array from columns | ||
| References: | 1 2 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-42389@lists.php.net to get a copy of this message | ||
Yea, thanks. I forgot to hit reply to all. I usually use sprintf for mysql
injection stuff. I use that function from php.net for
mysql_real_escape_string.
On 9/23/06, Matthias Willerich <matthias@die-legendaeren.de> wrote:
Hello, $q = sprintf("SELECT id FROM content"); This has nothing to do with your problem, but why don't you just do the following? $q = 'SELECT id FROM content'; But here's your problem. Change $realones = $row['id']; into $realones[] = $row['id']; And you get your desired result. Matthias-- Dave W