\n"; /* the database query to fetch the items */ $query = "SELECT * FROM news"; /* make 2 list to store html texts before we glue them togheter */ $news_items = array(); $news_item_groups = array(); /** fetch and make html of each database row **/ $resource = mysql_query($resource) OR die('query failed'); while($result = mysql_fetch_assoc($resource)) { /* design html for each row */ $news_html = "
{$result['content']}
"; $news_html .= "