Support

Account

Home Forums Add-ons Repeater Field Loops files with URL Reply To: Loops files with URL

  • Hi Nuro. Thanks.

    This isn’t working though. The output is just blank, and I definitely substituted your field names with mine:

     <?php
    
      $rows = get_field('files-ra');
    
      if($rows) {
    
        while(the_sub_field('files-ra')) {
    
              $file = the_sub_field('file');
              $name = the_sub_field('file_name');
    	
              echo '<li><a href="' . $file . '" title="' . $name . '">' . $name . '</a></li>' ;
    
    			  }
    
    		  }
    
    		?>

    It might be worth noting that earlier in the document is
    <?php if (have_posts()) : while (have_posts()) : the_post(); ?>

    I need that still right?

    Such confuse.