Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <div class="tab-pane" id="first-tab-content" role="tabpanel">
- <h2>Red items</h2>
- <?php while( have_rows('products') ): the_row();
- $name = get_sub_field('name');
- $price = get_sub_field('price');
- $colors = get_sub_field('colors');
- if( in_array('red', $colors) ) { ?>
- Name: <?php echo $name; ?>
- Price: <?php echo $name; ?>
- <?php endwhile; ?>
- </div>
- <div class="tab-pane" id="second-tab-content" role="tabpanel">
- <h2>Blue items</h2>
- <?php while( have_rows('products') ): the_row();
- $name = get_sub_field('name');
- $price = get_sub_field('price');
- $colors = get_sub_field('colors');
- if( in_array('blue', $colors) ) { ?>
- Name: <?php echo $name; ?>
- Price: <?php echo $name; ?>
- <?php endwhile; ?>
- </div>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement