join

3 posts by 2 authors in: Forums > CMS Builder
Last Post: February 26, 2013   (RSS)

By Dave - February 26, 2013

Hi Tim, 

More recent CMSB versions should create a pseudo-field called $record['tags:labels'] that contains the labels.  Can you check if that's defined? Just do this:

<?php showme($record); ?>

If it is, you can create list items like this (untested code): 

<?php foreach ($record['tags:labels'] as $label): ?>
  <li><?php echo htmlencode($label); ?></li>
<?php endforeach ?>

// or if you prefer straight php:
<?php foreach ($record['tags:labels'] as $label) { print "<li>" .htmlencode($label). "</li>\n"; } ?>

Use whichever is more readable to you.

Let me know if either of those work for you.  Thanks!

Dave Edis - Senior Developer
interactivetools.com

Hey Dave,

Thanks Dave - that works great - I just had to remove the htmlencode

Cheers,

Tim (toledoh.com.au)