Toolset Types
[resolved] Custom Feild Checkbox - how to remove comma from output? (3 posts)

  1. Bill Gilmore
    Posted 3 years ago #

    I'm using the check boxes to add list items to an unordered list. I really don't want those commas on the output as the list items are image icons.

    I had a look at the API on the AFC website but it was no help to me, I'm pretty new to php so please keep it simple for me if you can help.

    Thanks any help would be really appreciated.


  2. Bill Gilmore
    Posted 3 years ago #

    ok this is totally non-semantic but unless anyone can help me update the PHP, I have a CSS fix to remove the commas. Below my unordered list opens and closes with a span tag to wrap the list items.

    <span><?php echo(types_render_field("facilities", array("arg1"=>"val1","arg2"=>"val2"))); ?></span>

    Each list item starts with a close span tag, and ends with and open span style which is displaying none. This means anything between list items is not displayed.

    </span><li class="cooking">Cooking</li><span style="display:none">

    Total work around but if any PHP developer can show me how to remove the comma from the output it would be appreciated. Cheers

  3. Bruz
    Posted 3 years ago #

    Add "separator"=>"" in your array like this :

      <span><?php echo(types_render_field("facilities", array("arg1"=>"val1","arg2"=>"val2", "separator"=>""))); ?></span>

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Toolset Types
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic