Hello all,
I am facing problem in how to set privacy(nobody,friends)on particular field like personal information form,i would like to show user detail as per their chioce,suupose if he/she want to show their birthday detail to only friends than only friends can see this

CommentFileSizeAuthor
forum.png181.53 KBparulk

Comments

gilgabar’s picture

Assigned: parulk » Unassigned
Category: feature » support
Priority: Major » Normal

You should do this in a preprocess function for the template where you are displaying the fields. For each field that you want to check access for just call privacypu_check_access() to determine whether it should be displayed or not.

dinesh217’s picture

Issue summary: View changes

Hi gilgabar,
How do i preprocess function for the template where you are diplaying the fields. how can i do it? sorry am new to preprocessing functions.

Thanks & Regards,
Dinesh.

gilgabar’s picture

See the Drupal theming documentation: https://www.drupal.org/node/223430. Or this may also be helpful: http://themery.com/dgd7/advanced-theming/preprocess-process/implement. Or just google "drupal preprocess".