ogmenu_instance.page.inc in Organic Groups Menu (OG Menu) 8
Contains ogmenu_instance.page.inc..
Page callback for OG Menu instance entities.
File
ogmenu_instance.page.incView source
<?php
/**
* @file
* Contains ogmenu_instance.page.inc..
*
* Page callback for OG Menu instance entities.
*/
use Drupal\Core\Render\Element;
use Drupal\Core\Link;
use Drupal\Core\Url;
/**
* Prepares variables for OG Menu instance templates.
*
* Default template: ogmenu_instance.html.twig.
*
* @param array $variables
* An associative array containing:
* - elements: An associative array containing the user information and any
* - attributes: HTML attributes for the containing element.
*/
function template_preprocess_ogmenu_instance(array &$variables) {
// Helpful $content variable for templates.
foreach (Element::children($variables['elements']) as $key) {
$variables['content'][$key] = $variables['elements'][$key];
}
}
Functions
Name | Description |
---|---|
template_preprocess_ogmenu_instance | Prepares variables for OG Menu instance templates. |