publish );
$post_type = get_post_type_object( $type );
$text = _n( '%s ' . $post_type->labels->singular_name, '%s ' . $post_type->labels->name, $published, 'sportspress' );
$text = sprintf( $text, number_format_i18n( $published ) );
if ( current_user_can( $post_type->cap->edit_posts ) ) :
$output = '' . $text . '';
else :
$output = '' . $text . '';
endif;
echo '
' . wp_kses_post( $output ) . '';
endif;
endforeach;
return $items;
}
/**
* Show status widget
*/
public function status_widget() {
?>
future ) ? $count->future : 0;
$published_count = isset( $count->publish ) ? $count->publish : 0;
$next_event = sp_get_next_event();
if ( $next_event ) :
$now = new DateTime( current_time( 'mysql', 0 ) );
$date = new DateTime( $next_event->post_date );
$interval = date_diff( $now, $date );
?>
-
%s until next event', 'sportspress' ) ), esc_html( $interval->days ) . ' ' . esc_html__( 'days', 'sportspress' ) . ' ' . sprintf( '%02s:%02s:%02s', esc_html( $interval->h ), esc_html( $interval->i ), esc_html( $interval->s ) ) ); ?>
(post_title ); ?>)
-
%s event scheduled', '%s events scheduled', $scheduled_count, 'sportspress' ) ), esc_attr( $scheduled_count ) ); ?>
-
%s event published', '%s events published', $published_count, 'sportspress' ) ), esc_attr( $published_count ) ); ?>
get_item_quantity( 5 );
// Build an array of all the items, starting with element 0 (first element).
$rss_items = $rss->get_items( 0, $maxitems );
}
if ( ! empty( $maxitems ) ) {
?>