How to display *block number* instead *date value* on WordPress posts?

I have no idea what a ‘block number’ is, but when themes output the date for a post they will use either the_date() or the_time() (or both). You can replace the output using the filters the_date() or the_time(): add_filter( ‘the_date’, function( $the_date, $format ) { $block_number=”whatever a block number is”; return $block_number; }, 10, 2 … Read more

Sorting past events by month

Using query_posts is pretty much always a bad idea as it causes another database query but it also will break pagination and can cause other issues as well. What you need it a filter on pre_get_posts. function pgp($qry) { if (!is_admin() && is_main_query() && $qry->is_category(3709)) { $qry->set(‘orderby’,’meta_value’); $qry->set(‘meta_key’,’Deadline’); //formatted YYYYMMDD $qry->set(‘ignore_sticky_posts’,true); } return $qry; } … Read more