Hi everyone!
I try to show a code with the repeater feature in ACF Pro into a while bucle.
My line code is the next:
<?php
if(have_rows('otros_archivos')):
while ( have_rows('otros_archivos') ) : the_row();
$antecedente = the_sub_field('antecedente');
echo "<a href='".$antecedente."' target='_blank'> '".$antecedente."' </a><br/>";
endwhile;
endif;
?>
And this my line code with the mistake:
echo "<a href='".$antecedente."' target='_blank'> '".$antecedente."' </a><br/>";
The first variable $antecedente is shows, but no like a link and the second $antecedente shows this text: ”
I would very much appreciate your help.
Best regards from Chile.
P.S.: I’m so sorry for my bad English lenguage, I’ll try to improve it someday.
EDITED
This is my edited code that works finally!!:
`<?php if(have_rows(‘otros_archivos’)):
while ( have_rows(‘otros_archivos’) ) : the_row(); ?>
<a href=”<?php the_sub_field(‘antecedente’); ?>” target=”_blank”><?php the_sub_field(‘antecedente’); ?></a><br/>
<?php endwhile; ?>
<?php endif; ?>`