theme_location == 'primary') $items .= '
'; return $items; } /** * Filter to allow child templates from client folder prior to child-theme */ add_filter('template_include', function ($template) { $path = explode('/', $template); $template_chosen = end($path); $grandchild_template = get_template_directory() . '/client/' . $template_chosen; if (file_exists($grandchild_template)) { $template = $grandchild_template; } return $template; });