Support » Plugin: Toolset Types - Custom Post Types, Custom Fields and Taxonomies » [Plugin: Types – Custom Fields and Custom Post Types Management] Checkboxes output?

  • Hey there,

    I’m using Types Fields API and try to echo a “checkboxes” custom field. I put in 6 elements, and checked the value 1, 2 and 5 for a demo.

    echo(types_render_field("my-checkboxes", array("raw"=>"false", "show_name"=>"false"));
    This does almost what i want. It shows: “value1, value2, value5”. Now, I want to change the “, ” between the values. I want to write the text “or” between them, so it would export “value1 or value2 or value5”.

    How can I manage this? It would also be okay to get an array or something, but I have no idea what to do. If I put “raw” to “true”, it simply echos the word “Array”, but I don’t know how to get an array out of it that works correct.

    Thank you so much,
    chatloxx

    http://wordpress.org/extend/plugins/types/

Viewing 1 replies (of 1 total)
  • Ahhhh, I just did a dumb try to add “separator”=>” or” – and it worked!

    Problem solved. But, does anyone know how to output, how many options I chose? So, as I chose thee of my five options, how can I output the number “3“? Like the size of an array?

Viewing 1 replies (of 1 total)
  • The topic ‘[Plugin: Types – Custom Fields and Custom Post Types Management] Checkboxes output?’ is closed to new replies.