31 lines
823 B
PHP
31 lines
823 B
PHP
<?php
|
|
/**
|
|
* Template part for displaying a list with data checked in checkbox list
|
|
*
|
|
* @link https://developer.wordpress.org/themes/basics/template-hierarchy/
|
|
*
|
|
* @package Xarxaprod_theme
|
|
*/
|
|
|
|
?>
|
|
|
|
<?php
|
|
// https://developer.wordpress.org/reference/functions/get_template_part/#comment-4130
|
|
// to display this template use
|
|
// get_template_part( 'template-parts/section', 'list-checkbox', array('iterate_field' => 'CHANGETHIS') );
|
|
$fielditerate = $args['iterate_field'];
|
|
?>
|
|
|
|
<?php
|
|
$fields= get_field($fielditerate);
|
|
if( $fields ):
|
|
?>
|
|
<ul class="xarxarprod-label item-<?php echo $fielditerate ?>">
|
|
<?php foreach( $fields as $field ): ?>
|
|
<li>
|
|
<?php echo $field['label']; ?>
|
|
</li>
|
|
<?php endforeach; ?>
|
|
</ul>
|
|
<?php endif; ?>
|