You could do something like:
$result = mysql_query("SELECT * FROM whatever", $link);
while ($topic = mysql_fetch_assoc($result)) {
        $all[] = $topic;
}

The array $all will contain all of the things fetched.

On Wed, 2004-09-29 at 02:04, Niklas Ojala wrote:
> Hello
> 
> I am kind of new to this news thing, but here goes.
> 
> I am looking for a class or some samples that would read a table from mysql
> and store it in an array variable, so that it will be avilable to other
> parts of the page without having to get it from the database again. So I
> would like to only get the table once per page load but I must be able to
> filter the table to get the data that I want.
> 
> I am looking for some similar code to get me started or other ideas on how
> to make less queries to the database.
> 
> /Niklas Ojala

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to