• Lets say you don’t want an excerpt, but you want to just add a description.

    Like the meta description instead for example.

    Is there a way to do this?

Viewing 1 replies (of 1 total)
  • Plugin Author Tom

    (@edge22)

    Hi there,

    You could turn off the content inside your list settings.

    Then add your description to a hook:

    add_action( 'wpsp_before_content', function( $settings ) {
        if ( 123 === $settings['list_id'] ) {
            $description = get_post_meta( get_the_ID(), 'your_custom_field', true );
    
            if ( $description {
                echo $description;
            }
        }
    } );

    So in the code above, we check the list ID so it only applies the list you need. You’ll need to update 123 with the ID of your list.

    Then it uses a custom field to add content. So you’d need to update your_custom_field with the name of your custom field that has the description.

    Hope this helps ??

Viewing 1 replies (of 1 total)
  • The topic ‘Custom Description/Except’ is closed to new replies.