<?php if (have_rows('slider', 59)) : while (have_rows('slider', 59)) : the_row(); ?>
<?php echo wp_get_attachment_image(get_sub_field('slider-image'), 'large', false, array("loading" => "lazy")); ?>
<?php endwhile; endif; ?>
$my_repeater = get_field('my_repeater_field', 'id страницы к которой он привязан');
// можно обращаться к его полям, например:
echo $my_repeater['3']['название строки'];
<div class="tabs">
<?php if( have_rows('gallery') ) : while ( have_rows('gallery') ) : the_row(); ?>
<span id="gallery-<?php echo get_row_index(); ?>"><?php the_sub_field('gallery_name'); ?></span>
<?php endwhile; endif; ?>
</div>
<?php if( have_rows('gallery') ) : while ( have_rows('gallery') ) : the_row(); ?>
<?php if( have_rows('gallery_item') ) : while ( have_rows('gallery_item') ) : the_row(); ?>
<div data-gallery="gallery-<?php echo get_row_index(); ?>" class="gallery"></div>
<?php endwhile; endif; ?>
<?php endwhile; endif; ?>
<?php
$week_day = [
1 => 'ПН', 2 => 'ВТ', 3 => 'СР', 4 => 'ЧТ', 5 => 'ПТ', 6 => 'СБ', 7 =>'ВС'
];
foreach ($week_day as $key => $day) { ?>
<div class="item <?php echo ($key == wp_date('N') ? 'current_day' : '') ?>"><?php echo $day; ?></div>
<?php } ?>
$my_posts = get_posts(array(
'numberposts' => 0,
'category' => 14,
'orderby' => 'meta_value_num',
'meta_key' => 'skidka'
));
foreach ($my_posts as $post) :
setup_postdata($post);
?>
<a href="<?php the_permalink(); ?>"><?php the_title(); ?></a>
<?php endforeach; ?>
$sort_tag = [];
foreach ($terms as $term) {
$sort_tag[$term->name] = esc_url(get_term_link($term->term_id));
}
ksort($sort_tag, SORT_NATURAL);
foreach ($sort_tag as $tag_name => $tag_url) {
echo '<li><a href="' . $tag_url . '">' . $tag_name .'</a></li>';
}