You are here

function User::render_link in Views (for Drupal 7) 8.3

2 calls to User::render_link()
Mail::render_link in lib/Views/user/Plugin/views/field/Mail.php
User::render in lib/Views/user/Plugin/views/field/User.php
Render the field.
3 methods override User::render_link()
Language::render_link in lib/Views/user/Plugin/views/field/Language.php
Mail::render_link in lib/Views/user/Plugin/views/field/Mail.php
Name::render_link in lib/Views/user/Plugin/views/field/Name.php

File

lib/Views/user/Plugin/views/field/User.php, line 55
Definition of Views\user\Plugin\views\field\User.

Class

User
Field handler to provide simple renderer that allows linking to a user.

Namespace

Views\user\Plugin\views\field

Code

function render_link($data, $values) {
  if (!empty($this->options['link_to_user']) && user_access('access user profiles') && ($uid = $this
    ->get_value($values, 'uid')) && $data !== NULL && $data !== '') {
    $this->options['alter']['make_link'] = TRUE;
    $this->options['alter']['path'] = "user/" . $uid;
  }
  return $data;
}