Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
i use taxonomy term fields. module entity API enabled. i want to output term field value. the following code
dsm($node->field_myfield['und'][0]['taxonomy_term']->field_type['und'][0]['value']);
works in devel PHP block, but not in views PHP field.
print($data->nid);
$node=node_load($data->nid);
print ($node->field_myfield['und'][0]['taxonomy_term']->field_type['und'][0]['value']);
i can't access array element 'taxonomy_term'. can you help me?
Comments
Comment #1
arpas CreditAttribution: arpas commentedprobably the problem is my narrow experience with views 3 and taxonomy. I found what taxonomy in views require relationship. any suggestions?
Comment #2
Liam Morland