Probling getting rows from DB
Posted: Mon Apr 04, 2005 6:01 am
After a night with no sleeping at all, I'm starting to make some stupid mistakes, I'm trying to store the arrays ($row) coming from database in a new longer array called $despdef:
The fact is that I only get 1 row from DB, I know is obvious,
but I'm too
o
o
o
tired...
Code: Select all
$desp = mysql_num_rows($rs);
if(($desp<15)&&($desp>0)){
$desp2=15;
for($f=0;$f<$desp;$f++){
while ($row = mysql_fetch_array($rs)){
$despdef[$f]=$row;
}}
for($d=$desp;$d<$desp2;$d++){
$despdef[$d]=0;
}}but I'm too
o
o
o
tired...