template_preprocess_filter_tips(&$variables)
Prepares variables for filter tips templates.
Default template: filter-tips.html.twig.
array $variables: An associative array containing:
array( 'Full HTML' => array( 0 => array( 'tip' => 'Web page addresses and email addresses turn into links automatically.', 'id' => 'filter/2', ), ), );
function template_preprocess_filter_tips(&$variables) { $tips = $variables['tips']; foreach ($variables['tips'] as $name => $tiplist) { foreach ($tiplist as $tip_key => $tip) { $tiplist[$tip_key]['attributes'] = new Attribute(); } $variables['tips'][$name] = array( 'attributes' => new Attribute(), 'name' => $name, 'list' => $tiplist, ); } $variables['multiple'] = count($tips) > 1; }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!modules!filter!filter.module/function/template_preprocess_filter_tips/8.1.x