Hi everyone. I am in a bit of a bind. I am trying to write a script that will query a database, return the news sorted by the date (newset first), and then to group news articles together by their date, sorted by time.
My current page is here . I think you can get a good understanding of what I am trying to do. Something similar to the news grouping at sites like GTAGaming.com .
I greatly appreciate any help.
EDIT:
Sorry, I forgot the PHP. Here is my code that I am running.
<?php
$query_news = mysql_query("SELECT * FROM news ORDER BY news_date DESC");
$news = mysql_fetch_assoc($query_news);
do { ?>
<tr>
<td><?php echo $news['news_date']; ?></td>
</tr>
<tr>
<td><?php echo $news['news_title']; ?><br />
Posted by <?php echo $news['news_author']; ?> at <?php echo $news['news_time']; ?></td>
</tr>
<tr>
<td><?php echo $news['news_text']; ?></td>
</tr>
<?php } while ($news = mysql_fetch_assoc($query_news)); ?>