Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- // check if the repeater field has rows of data
- if( have_rows('menu_sections') ):
- // loop through the rows of data
- while ( have_rows('menu_sections') ) : the_row();?>
- <h2>
- <?php the_sub_field('section_title');?>
- </h2>
- <?php if(get_sub_field('menu_description')) ?>
- <?php
- endwhile;
- else :
- echo "Ingen retter funnet";
- endif;
- ?>
- <?php
- // check if the repeater field has rows of data
- if( have_rows('section_items') ):
- // loop through the rows of data
- while ( have_rows('section_items') ) : the_row(); ?>
- <h3>
- <?php the_sub_field('rett_navn'); ?>
- </h3>
- <p>
- <?php the_sub_field('rett_beskrivelse'); ?>
- </p>
- <p>
- <?php the_sub_field('rett_allergener'); ?>
- </p>
- <p>
- <?php the_sub_field('rett_pris'); ?>
- </p>
- <?php
- endwhile;
- else :
- echo "Ingen rader funnet";
- endif;
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement