Re: [PHP] how to extract fields from associative array into different variables

[email protected] (kranthi)
Newsgroups php.general
Message-ID <[email protected]>
you dont have an alternative. you will have to loop because
mysql_fetch_* functions fetch only one row at a time.

you can use variable variables to achieve the above result (you will
not require this if u use list() or extract() functions)
http://us.php.net/manual/en/language.variables.variable.php

and if you cant do the job with arrays, and u need separate variables
list would be an useful function as suggested earlier.
you may also consider using http://in.php.net/manual/en/function.extract.php
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.