Skip to content

Instantly share code, notes, and snippets.

View danielmme's full-sized avatar

Daniel M. Medeiros danielmme

  • Innovare Technologies
  • São José dos Campos
  • 08:05 (UTC -12:00)
View GitHub Profile
F<?php
function THEMENAME_menu_link(array $variables) {
$element = $variables['element'];
$sub_menu = '';
if ($element['#below']) {
$sub_menu = drupal_render($element['#below']);
}
if (empty($element['#localized_options'])) {
@danielmme
danielmme / menu.php
Created March 9, 2017 20:03
call menu in drupal tpl
$menu = menu_navigation_links('menu-your-custom-menu-name');
print theme('links__menu_your_custom_menu_name', array('links' => $menu));