how to limit the column or fields to only a sepecafic role in views Drupal?

46 Views Asked by At

I have created a view of basic pages content type in drupal and I want to make visible the title field in a view to only admin user and all other fields or column should be visible to all other users including admin. please any one have idea about this?

1

There are 1 best solutions below

0
On BEST ANSWER

Issue is solved now, solution: create a php field and add following snippet.

roles)) { print '$'. $data->_field_data['nid']['entity']->field_name_to_display['und'][0]['value']; }else{ print "no access"; } ?>