Support

Account

Home Forums Add-ons Repeater Field Repeater field – only show one row

Helping

Repeater field – only show one row

  • Hi, here is my code and this shows only one row of content. Any help will be really appreciated.
    Thanks
    if(have_rows(‘columns_section’)) : while(have_rows(‘columns_section’)) : the_row();

    $sbtn1 = get_sub_field(‘linkone’);
    $sbtn2 = get_sub_field(‘linktwo’);
    $sbtn3 = get_sub_field(‘linkthree’);
    $sbtn4 = get_sub_field(‘linkfour’);
    $link_url = $sbtn1[‘url’];
    $link_url2 = $sbtn2[‘url’];
    $link_url3 = $sbtn3[‘url’];
    $link_url4 = $sbtn4[‘url’];
    $sbtn1html = “{$sbtn1[‘title’]}“;
    $sbtn2html = “{$sbtn2[‘title’]}“;
    $sbtn3html = “{$sbtn3[‘title’]}“;
    $sbtn4html = “{$sbtn4[‘title’]}“;

    endwhile; endif;

  • Is is showing only one row or do you want it to show only one row?

    Where are you outputting the values you’re getting from the row? This is not shown in your code.

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.