<?php

if (!defined('ABSPATH')) {
    exit;
}
// Exit if accessed directly
$menu = apply_filters('weaverx_menu_name', 'secondary');
if (weaverx_getopt('m_secondary_hide') != 'hide' && has_nav_menu($menu) && !weaverx_is_checked_page_opt('_pp_hide_menus')) {
    $class = weaverx_menu_class('m_secondary');
    $left = weaverx_getopt('m_secondary_html_left');
    $right = weaverx_getopt('m_secondary_html_right');
    if ($left) {
        $hide = ' ' . weaverx_getopt('m_secondary_hide_left');
        $left = '<span class="wvrx-menu-html wvrx-menu-left' . $hide . '">' . do_shortcode($left) . '</span>';
        $left = str_replace('%', '%%', $left);
        // wp_nav_menu uses sprintf! This will almost always fix the issue.
    } elseif (is_customize_preview()) {
        $hide = ' ' . weaverx_getopt('m_secondary_hide_left');
        $left = '<span class="wvrx-menu-html wvrx-menu-left' . $hide . '"></span>';
    }
    if ($right) {
        $hide = ' ' . weaverx_getopt('m_secondary_hide_right');
        $right = '<span class="wvrx-menu-html wvrx-menu-right ' . $hide . '">' . do_shortcode($right) . '</span>';
        $right = str_replace('%', '%%', $right);
        // wp_nav_menu uses sprintf!
    } elseif (is_customize_preview()) {
        $hide = ' ' . weaverx_getopt('m_secondary_hide_right');
        $right = '<span class="wvrx-menu-html wvrx-menu-right ' . $hide . '"></span>';
    }
    $use_smart = weaverx_getopt('use_smartmenus') && function_exists('weaverxplus_plugin_installed');
    if ($use_smart) {
<?php

if (!defined('ABSPATH')) {
    exit;
}
// Exit if accessed directly
$menu = apply_filters('weaverx_menu_name', 'primary');
if (weaverx_getopt('m_primary_hide') != 'hide' && !weaverx_is_checked_page_opt('_pp_hide_menus')) {
    $use_smart = weaverx_getopt('use_smartmenus') && function_exists('weaverxplus_plugin_installed');
    weaverx_clear_both('menu-primary');
    $class = weaverx_menu_class('m_primary');
    $align = weaverx_getopt('m_primary_align');
    $left = weaverx_getopt('m_primary_html_left');
    $right = weaverx_getopt('m_primary_html_right');
    if ($left) {
        $hide = ' ' . weaverx_getopt('m_primary_hide_left');
        $left = '<span class="wvrx-menu-html wvrx-menu-left' . $hide . '">' . do_shortcode($left) . '</span>';
        $left = str_replace('%', '%%', $left);
        // wp_nav_menu uses sprintf! This will almost always fix the issue.
    } elseif (is_customize_preview()) {
        $hide = ' ' . weaverx_getopt('m_primary_hide_left');
        $left = '<span class="wvrx-menu-html wvrx-menu-left' . $hide . '"></span>';
    }
    if ($right) {
        $hide = ' ' . weaverx_getopt('m_primary_hide_right');
        $right = '<span class="wvrx-menu-html wvrx-menu-right ' . $hide . '">' . do_shortcode($right) . '</span>';
        $right = str_replace('%', '%%', $right);
        // wp_nav_menu uses sprintf!
    } elseif (is_customize_preview()) {
        $hide = ' ' . weaverx_getopt('m_primary_hide_right');
        $right = '<span class="wvrx-menu-html wvrx-menu-right ' . $hide . '"></span>';
<?php

if (!defined('ABSPATH')) {
    exit;
}
// Exit if accessed directly
/**
 * @package WordPress
 * @subpackage weaverx
 */
if (has_nav_menu('header-mini')) {
    // weaverx_getopt( 'm_header_mini_hide') != 'hide' &&
    $class = weaverx_menu_class('m_header_mini');
    echo "\n\n<div id=\"nav-header-mini\" class=\"menu-horizontal {$class}\">\n";
    // echo '<span style="display:inline;float:left;color:yellow;padding-top:.2em;">LEFT</span>';
    wp_nav_menu(array('fallback_cb' => '', 'theme_location' => 'header-mini', 'menu_class' => 'wvrx-header-mini-menu', 'container' => 'div', 'container_class' => ''));
    // echo '<span style="display:inline;float:right;">RIGHT</span>';
    weaverx_clear_both('header-mini');
    echo "\n</div><!-- /#nav-header-mini -->\n";
    weaverx_clear_both('nav-header-mini');
}