I've made a tag cloud for my dates and a second page where, after you click on a tag it displays the data found in the database for that day. Now this method has worked up till this year. For some reason once it turned 2008 the second page that displays the data no longer works correctly but when clicking on 2007 items in the tag cloud they load fine. So heres the gist of what I'm doing. In mysql I have a field called date which saves the date and time (ex. 2008-01-09 18:19:00 ). When I click on a Tag I just want to display the data for that day (ie. 2008-01-09) and order it by the date and time. So I've been doing it with this line
$sql = "SELECT * FROM `headlines` WHERE DATE_FORMAT(date, '%Y-%c-%d') = '$date' ORDER BY date DESC LIMIT 0, 30";
But for some reason it does not work with dates other then 2007 now...can anyone explain how I can fix this. Btw variable $date equals the date a user clicks on, so for example 2008-01-25.
I hope I was clear enough.