Which method is good for getting values ββfrom an array used in loops.
1. list()
2. extract()
3. Normal extracting like $array['id']
code snippet:
$sel = mysql_query("SELECT id,name from user");
while($get = mysql_fetch_array($sel)){
extract($get);
loop($id,$name)=$get;
$id = $get['id'];
}
I like to know the pros and cons of these methods. or any other method exists.
thank
source
share