excerpt custom post type

Solutions on MaxInterview for excerpt custom post type by the best coders in the world

showing results for - "excerpt custom post type"
Roberto
03 Mar 2018
1Change your support field to this 
2'supports' => array( 'title', 'editor', 'author', 'thumbnail', 'excerpt', 'comments' ) );
3
4Eg:
5<?php
6add_action( 'init', 'create_testimonial_posttype' );
7function create_testimonial_posttype(){
8  register_post_type( 'testimonials',
9    array(
10      'labels' => array(
11        'name' => __( 'Testimonials' ),
12        'singular_name' => __( 'Testimonial' )
13      ),
14      'public' => true,
15      'has_archive' => true,
16      'rewrite' => array('slug' => 'clients'),
17      'supports' => array('title','thumbnail','editor','page-attributes','excerpt'),
18    )
19  );
20}
21?>