custom fields in twenty twenty one
-
For accessibility, the READ MORE on posts needs to be customized – i.e. you cannot have multiple duplicated “READ MORE” links on the same page.
In twenty twenty, i added the following code to functions:`add_filter( ‘pt_cv_dargs_others’, ‘cvp_theme_change_readmore_text_per_post’, 999, 2 );
function cvp_theme_change_readmore_text_per_post( $dargs, $post_idx ) {
global $post;
$meta = get_post_meta( $post->ID );
if ( !empty( $meta[ ‘cvp_readmore_text’ ][ 0 ] ) ) {
$dargs[ ‘field-settings’ ][ ‘content’ ][ ‘readmore-text’ ] = $meta[ ‘cvp_readmore_text’ ][ 0 ];
}
return $dargs;
}`I added this to twenty twenty one, but cannot find how to turn on Custom fields. It was a Preference in Twenty Twenty.
- The topic ‘custom fields in twenty twenty one’ is closed to new replies.