1) Nothing displays on the page at first except the row of Years
2) User clicks on year and it loads the associated months in that row
3) User clicks on specific month and it loads the posts below in that area
I am having a hell of a time trying to figure out how best to accomplish this, any ideas to help point me in the right direction would be greatly appreciated.
$months = $wpdb->get_col("SELECT DISTINCT MONTH(post_date) FROM $wpdb->posts WHERE post_status = 'publish' AND post_type = 'post' AND YEAR(post_date) = '".$year."' ORDER BY post_date DESC");
foreach($months as $month):