Elementor: Finde custom post type

add_action( ‘elementor/query/my_custom_filter’, function( $query ) {
// Here we set the query to fetch posts with
// post type of ‘custom-post-type1’ and ‘custom-post-type2’
$query->set( ‘post_type’, [ ‘custom-post-type1’, ‘custom-post-type2’ ] );
} );

Leave a comment

Your email address will not be published. Required fields are marked *