שלום יש לי את זה:
PHP קוד:
$result = mysql_query("select title from content");
$row = mysql_fetch_object($result);
while($row = mysql_fetch_object($result)){
foreach ($row as $key => $val){
$elements=array($key => $row->$key);
}
}
וכל הזמן הוא מחזיר לי רק את האחרון נגיד שיש לי טבלה כזאת:
title
____
home
title2
title3
אז הוא תמיד מחזיר לי את title3
איך אני עושה שהוא יחזיר לי את כולם?
ככה:
PHP קוד:
element['title']='home'
element['title']='title2'
element['title']='title3'
thanks