Ok, so here’s my code:
$query2005 = “SELECT * FROM king_news WHERE DATE_FORMAT(news_date, ‘%Y’) = 2005”;
$result2005 = mysql_query($query2005);
$article = mysql_fetch_array($result2005);
I have the dates stored in the column ‘news_date’ in the ‘king_news’ table. Why is it that the query I have doesn’t pull up anything? I have the dates stored as a PHP timestamp (seconds after dec. 31, 1969).
I use this same query (basically) in another page and it seems to work fine.
I think it has something to do with the date_format function in the sql query, however I probably don’t know what I’m talking about.
Any help would be GREATLY appreciated!
Thanks,
Will ?
EDIT: BTW, here’s the page address:
[url]http://www.summel.net/archive.php
Thanks again!