You are here

function template_preprocess_redhen_connection in RedHen CRM 8

Prepares variables for Connection templates.

Default template: redhen_connection.html.twig.

Parameters

array $variables: An associative array containing:

  • elements: An associative array containing the user information and any
  • attributes: HTML attributes for the containing element.

File

modules/redhen_connection/redhen_connection.page.inc, line 24
Contains redhen_connection.page.inc..

Code

function template_preprocess_redhen_connection(array &$variables) {

  // Fetch Connection Entity Object.
  $redhen_connection = $variables['elements']['#redhen_connection'];

  // Helpful $content variable for templates.
  foreach (Element::children($variables['elements']) as $key) {
    $variables['content'][$key] = $variables['elements'][$key];
  }
}