function views_handler_field_contact_link::access in Views (for Drupal 7) 6.2
Same name and namespace in other branches
- 6.3 modules/contact/views_handler_field_contact_link.inc \views_handler_field_contact_link::access()
- 7.3 modules/contact/views_handler_field_contact_link.inc \views_handler_field_contact_link::access()
Check whether current user has access to this handler.
Return value
boolean
Overrides views_handler_field_user_link::access
File
- modules/
contact/ views_handler_field_contact_link.inc, line 32
Class
- views_handler_field_contact_link
- A field that links to the user contact page, if access is permitted.
Code
function access() {
global $user;
// Only registered users can view other registered user's contact page.
if (empty($user->uid)) {
return FALSE;
}
return TRUE;
}