I make It works with Future Posts!
-
Here I explained how I harcoded the plugin in my functions.php archive.
Now, I want to share with all of you how to make plugin to work with Future Posts.
Just look at this part of the code:
// Get days with posts $sql = "SELECT DISTINCT DAYOFMONTH(post_date) FROM $wpdb->posts " . calcat_maybe_single_category_joins( $category ) . "WHERE MONTH(post_date) = '$thismonth' AND YEAR(post_date) = '$thisyear'" . calcat_maybe_single_category_cat( $category ) . " AND post_type = 'post' AND post_status = 'publish' AND post_date < '" . current_time( 'mysql' ) . '\'';
Remove “AND post_date…”. The code have to look like this:
$sql = "SELECT DISTINCT DAYOFMONTH(post_date) FROM $wpdb->posts " . calcat_maybe_single_category_joins( $category ) . "WHERE MONTH(post_date) = '$thismonth' AND YEAR(post_date) = '$thisyear'" . calcat_maybe_single_category_cat( $category ) . " AND post_type = 'post' AND post_status = 'publish'";
I hope it helps you!
ps: sorry for my english.
https://www.ads-software.com/extend/plugins/calendar-category/
Viewing 12 replies - 1 through 12 (of 12 total)
Viewing 12 replies - 1 through 12 (of 12 total)
- The topic ‘I make It works with Future Posts!’ is closed to new replies.