You appear to be a bot. Output may be restricted
Description
Republish posts from a chosen category, setting a new published time if required
Usage
oik_batchmove_category_republish( $cat, $time, $verbose );
Parameters
- $cat
- ( string ) required – The Category ID to republish
- $time
- ( string ) required – the target time in format hh:mmm
- $verbose
- ( bool ) optional – whether or not to display activity
Returns
voidSource
File name: oik-batchmove/admin/oik-batchmove-cron.phpLines:
1 to 24 of 24
function oik_batchmove_category_republish( $cat, $time, $verbose=false ) { $post_date = oik_batchmove_query_oldest_date( $cat ); if ( $post_date ) { $posts = oik_batchmove_query_reposts( $post_date, $cat ); if ( $verbose ) { p( "Rescheduling posts for $post_date, category: $cat, time: $time" ); } if ( $posts ) { foreach ( $posts as $post ) { if ( $verbose ) { p( "Rescheduling: " . $post->ID ); } oik_batchmove_republish_post( $post, $cat, $time ); } } else { $posts = null; p( "No posts to reschedule: $cat" ); } } else { p( "No posts to reschedule for $cat" ); } }View on GitHub View on Trac