array( 'name' => __( 'Viator Tours', 'viator-collector' ), 'singular_name' => __( 'Viator Tour', 'viator-collector' ), 'add_new_item' => __( 'Add New Viator Tour', 'viator-collector' ), 'edit_item' => __( 'Edit Viator Tour', 'viator-collector' ), ), 'public' => true, 'has_archive' => true, 'rewrite' => array( 'slug' => 'tours' ), 'show_in_rest' => true, 'menu_icon' => 'dashicons-location-alt', 'supports' => array( 'title', 'editor', 'excerpt', 'thumbnail', 'custom-fields' ), ) ); } public static function add_featured_box() { add_meta_box( 'vc_featured', __( 'Featured', 'viator-collector' ), array( __CLASS__, 'render_featured_box' ), 'viator_tour', 'side', 'high' ); } public static function render_featured_box( $post ) { wp_nonce_field( 'vc_featured', 'vc_featured_nonce' ); $on = (int) get_post_meta( $post->ID, '_vc_featured', true ); ?> '; } } }