diff --git a/includes/navwalker.php b/includes/navwalker.php deleted file mode 100644 index 7b9bdb0..0000000 --- a/includes/navwalker.php +++ /dev/null @@ -1,28 +0,0 @@ -"; - - } - - function start_el(&$output, $item, $depth = 0, $args = null, $id = 0) - { - - $output .= "
  • I like pie" . $item->title; - - // var_dump($args); - } - - function end_el(&$output, $item, $depth = 0, $args = null) - { - $output .= "...
  • "; - } - -} \ No newline at end of file diff --git a/includes/nawalker_fction.php b/includes/nawalker_fction.php deleted file mode 100644 index 5ad3bdc..0000000 --- a/includes/nawalker_fction.php +++ /dev/null @@ -1,91 +0,0 @@ -classes = array_merge($item->classes, array('menu-item-' . $item->ID)); - - // #### MENU HOMEGRADE HEADER - if ($args->theme_location === "homegrade" && $args->menu_id === "menu-homegrade-navlist" && in_array('menu-item-has-children', $item->classes, true)) { - $output = ''; - } - - // #### MENU HOMEGRADE FOOTER - if ($args->theme_location === "homegrade" && $args->menu_class === "menu-homegrade-footer" && in_array('menu-item-has-children', $item->classes, true)) { - $output = '
    ' . $item->title . '
    '; - } - - - - if ($args->theme_location === "primary") { - $page_icon = get_field('page_icon', $item->object_id); - - - - if (isset($page_icon)) { - $icon = ''; - $link = $output; - $output = $icon . $link; - } - - - // #### TAXONOMY : GET ICON & INFOS ABOUT TAX - - - } - - if ($args->theme_location === "footer" && in_array('menu-item-has-children', $item->classes, true)) { - $output = $item->title; - } - return $output; -} -add_filter('walker_nav_menu_start_el', 'dynamiques_wrap_parent_menu_item_buttons', 10, 4); - - - - - - -/* ----------------------------------------------------------- - Pass Specific submenus-classnames for menu renovateur - -----------------------------------------------------------*/ - - - -function customize_submenu_classnames($classes, $args, $depth) -{ - // Here we can additionally use menu arguments. - // if ($args->theme_location === "renovateur") { - // $default_class_name_key = array_search('sub-menu', $classes); - - // if (false !== $default_class_name_key) { - // unset($classes[$default_class_name_key]); - // } - // $classes[] = 'header-submenu'; - // $classes[] = "depth-{$depth}"; - // $classes[] = 'sub-menu'; - // $classes[] = 'test'; - // } - - - return $classes; -} -// add_filter('nav_menu_submenu_css_class', 'customize_submenu_classnames', 10, 3); - - -/* ----------------------------------------------------------- - FILTER MENU OBJECTS TO BE DISPLAYED - -----------------------------------------------------------*/ - - -function wpdocs_unset_menu_items($menu_objects, $args) -{ - if ($args->theme_location === "renovateur") { - } - return $menu_objects; -} -// add_filter('wp_nav_menu_objects', 'wpdocs_unset_menu_items', 10, 2); \ No newline at end of file