Cytat
array(2) { [0]=> array(5) { ["id"]=> string(1) "1" ["title"]=> string(27) "Tytu? rzeczonego news'a... " ["content"]=> string(22) "Jaki? tam tekst news'a" ["autor"]=> string(6) "turgon" ["date"]=> string(19) "2006-12-30 13:41:26" } [1]=> array(5) { ["id"]=> string(1) "2" ["title"]=> string(10) "hafagagaga" ["content"]=> string(19) "Kolejna cze?? newsa" ["autor"]=> string(10) "Shur'tugal" ["date"]=> string(19) "2006-12-30 14:05:16" } }
Kod wykonujący:
<?php $this->view->title = $newses[$i]['title']; $this->view->content = $newses[$i]['content']; $this->view->date = $newses[$i]['date']; $this->view->autor = $newses[$i]['autor']; $this->view->loadView('news'); $pNews[] = $this->view->render(); } ?>
Najpierw był foreach, ale też nie działało, to zmieniłem na for. Może mi ktoś wyjaśnić ten fenomen
