Hi,
I have this function that I want to add to the edit bulk options, whereas the post_title bit should be replaced with a ACF custom field called keyword.
what would be the best way to do this, do I need to echo the value or … ?
thanks in advance
foreach( $posts as $p ) :
//set term as first letter of post title, lower case
$taxonomy = 'alphabetical_letter';
wp_set_post_terms( $p->ID, strtolower(substr($p->post_title, 0, 1)), $taxonomy );
endforeach;