49 lines
2.2 KiB
PHP
49 lines
2.2 KiB
PHP
<div class="owl-carousel quests-slider container">
|
|
<!-- Выводи список квестов -->
|
|
<?php
|
|
$posts = get_posts( array(
|
|
'category' => 0,
|
|
'orderby' => 'date',
|
|
'order' => 'ASC',
|
|
'include' => array(),
|
|
'exclude' => array(),
|
|
'meta_key' => '',
|
|
'meta_value' =>'',
|
|
'post_type' => 'armanty_quests',
|
|
'suppress_filters' => true, // подавление работы фильтров изменения SQL запроса
|
|
) );
|
|
|
|
foreach( $posts as $post ){
|
|
setup_postdata($post);?>
|
|
<div class="quests-container__quest" style="background: url('<?php echo the_post_thumbnail_url() ?>');">
|
|
<div class="quests-container__quest-overlay"></div>
|
|
<div class="quests-container__quest-content">
|
|
<div>
|
|
<h3><?php the_title();?></h3>
|
|
<p><?php the_excerpt();?></p>
|
|
<div class="quest-description__icons_main">
|
|
<div class="quest-people">
|
|
<img src="<?php echo get_template_directory_uri() ?>/assets//img/quests/quest-people-big-white.svg" alt="">
|
|
<span><?php the_field('quest_players_min')?>-<?php the_field('quest_players_max')?> игроков</span>
|
|
</div>
|
|
<div class="quest-time">
|
|
<img src="<?php echo get_template_directory_uri() ?>/assets//img/quests/quest-time-big-white.svg" alt="">
|
|
<span><?php the_field('quests_time')?> минут</span>
|
|
</div>
|
|
<div class="quest-age">
|
|
<img src="<?php the_field('quests_age')?>" alt="">
|
|
<!-- <i class="fa fa-child" aria-hidden="true"></i> -->
|
|
<!-- <span><?php echo the_field('quest_level'); ?> из 5</span> -->
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<a href="<?php echo the_permalink(); ?>"><button>Подробнее</button></a>
|
|
</div>
|
|
|
|
</div>
|
|
<?php
|
|
}
|
|
?>
|
|
|
|
|
|
</div>
|