Or, embed this snippet using GenerateWP WordPress Plugin.

Download

Clone

Loop Hraci

// WP_Query arguments
$args = array(
	'name'                   => 'hraci',
	'post_type'              => array( 'hraci' ),
	'nopaging'               => false,
	'posts_per_page'         => '6',
	'order'                  => 'DESC',
	'orderby'                => 'title',
	'meta_query'             => array(
		array(
			'key'     => 'tym',
			'value'   => 'Muži A',
			'compare' => 'LIKE',
			'type'    => 'CHAR',
		),
	),
);

// The Query
$r = new WP_Query( $args );

// The Loop
if ( $r->have_posts() ) {
	while ( $r->have_posts() ) {
		$r->the_post();
		// do something
	}
} else {
	// no posts found
}

// Restore original Post Data
wp_reset_postdata();