You are here

function theme_registration_registrant_link in Entity Registration 8.2

Same name and namespace in other branches
  1. 7.2 registration.module \theme_registration_registrant_link()

Theme handler for registrant links.

Parameters

array $variables: Contains the registrant type and entity.

Return value

string

File

./registration.module, line 1003

Code

function theme_registration_registrant_link($variables) {
  $registrant_type = $variables['registrant_type'];
  $registrant = $variables['registrant'];
  if ($registrant_type && $registrant) {
    $registrant_label = $registrant
      ->label();
    $registrant_uri = entity_uri($registrant_type, $registrant);

    // @FIXME
    // l() expects a Url object, created from a route name or external URI.
    // return l($registrant_label, $registrant_uri['path']);
  }
  return t('Anonymous');
}