How to get the values of a category field in an app

Comments

2 comments

  • Brian Stengaard

    Hi Victoria,

    Field values are attached to items. So you can get all items and loop through all fields for all items:

    function printField($app_id, $field_id) {
    $items = PodioItem::filter($app_id);
    foreach($items as $item) {
    print "Item ".$item->title."\n";
    foreach($item->fields as $i => $value) {
    if ($value->field_id == $field_id ){
    print $value;
    }
    }
    }
    }

    Cheers,

    Brian

    0
    Comment actions Permalink
  • Victoria Aparicio

    Hello Brian, I want to get all the values of a category field from an app.

    If I got the values from items, I Just got the selected, I want to get all the values from the template, please 

    0
    Comment actions Permalink

Please sign in to leave a comment.

Powered by Zendesk