selected_action ) {
// WP core labels
$text = 'Delete';
$label_apply = esc_attr__( $text );
$text = 'Cancel';
$label_cancel = esc_html__( $text );
// QFI strings
$question = __( 'Should the entries of featured images without image files be removed from the database?', 'quick-featured-images' );
} else {
// translate once for multiple usage and improve performance
$label_details = esc_html__( 'Details', 'quick-featured-images' );
$label_number = esc_html__( 'No.', 'quick-featured-images' );
$label_current_fi = esc_html__( 'Current Featured Image', 'quick-featured-images' );
$label_future_fi = esc_html__( 'Future Featured Image', 'quick-featured-images' );
$label_written_on = esc_html__( 'written on', 'quick-featured-images' );
$label_by = esc_html__( 'by', 'quick-featured-images' );
// WP core labels
$text = 'No image set';
$label_no_image = esc_html__( $text );
$text = 'Status:';
$label_status = esc_html__( $text );
$text = 'Apply';
$label_apply = esc_attr__( $text );
$text = 'Cancel';
$label_cancel = esc_html__( $text );
$text = '(no title)';
$default_title = esc_html__( $text );
// QFI strings
switch ( $this->selected_action ) {
case 'assign':
$question = __( 'Should the selected image be set as featured image to all listed posts?', 'quick-featured-images' );
break;
case 'assign_randomly':
$question = __( 'Should the selected images be set randomly as featured images to all listed posts?', 'quick-featured-images' );
break;
case 'replace':
$question = __( 'Should the current set featured image be replaced by the selected image at all listed posts?', 'quick-featured-images' );
break;
case 'remove':
$question = __( 'Should the selected image be removed from all listed posts?', 'quick-featured-images' );
break;
case 'assign_first_img':
$question = __( 'Should the future images be set as featured images at all listed posts?', 'quick-featured-images' );
break;
case 'remove_any_img':
$question = __( 'Should the added featured images be removed from all listed posts?', 'quick-featured-images' );
break;
} // switch()
?>
|
|
|
|
labels->singular_name; // readable name
}
// post status
$post_status = isset( $this->valid_statuses[ $result[ 6 ] ] ) ? $this->valid_statuses[ $result[ 6 ] ] : $result[ 6 ];
// check if no featured image for the post, else add default
$current_img = $result[ 4 ] ? $result[ 4 ] : $label_no_image;
$future_img = $result[ 5 ] ? $result[ 5 ] : $label_no_image;
// print the table row
printf( '', $row_classes );
printf( '| %d | ', $c );
printf(
'%s %s %s %s, %s %s | ',
esc_url( $result[ 0 ] ), // edit post link
$post_title,
$post_date,
$post_author,
esc_html( $post_type ),
$label_status,
esc_html( $post_status )
);
printf( '%s | ', $current_img );
printf( '%s | ', $future_img );
print "
\n";
// increase counter
$c++;
}
?>
|
|
|
|
selected_action )
?>