コード例 #1
0
ファイル: 03.header.php プロジェクト: oeuvrayjoris/grece
function thinkup_input_headerlocation()
{
    global $post;
    global $thinkup_header_styleswitch;
    global $thinkup_header_socialswitchmain;
    // Assign meta data variable
    if (!empty($post->ID)) {
        $_thinkup_meta_headerstyle = get_post_meta($post->ID, '_thinkup_meta_headerstyle', true);
    }
    // Reset variable values
    $class_header1_socialshow = NULL;
    $class_header2_socialshow = NULL;
    $class_header2_socialstart = NULL;
    $class_header2_socialend = NULL;
    // Assign variables to add #header social media icons next to logo for header style 1
    if (empty($_thinkup_meta_headerstyle) or $_thinkup_meta_headerstyle == 'option1') {
        if ($thinkup_header_styleswitch == 'option2' and $thinkup_header_socialswitchmain == '1') {
            $class_header1_socialshow = '1';
        }
    } else {
        if ($_thinkup_meta_headerstyle == 'option2') {
            $class_header1_socialshow = '1';
        }
    }
    // Assign variables to add #header social media icons next to logo for header style 2
    if (empty($_thinkup_meta_headerstyle) or $_thinkup_meta_headerstyle == 'option1') {
        if ($thinkup_header_styleswitch == 'option2' and $thinkup_header_socialswitchmain == '1') {
            $class_header2_socialstart = '<div id="header-container">';
            $class_header2_socialend = '</div>';
            $class_header2_socialshow = '1';
        }
    } else {
        if ($_thinkup_meta_headerstyle == 'option3') {
            $class_header2_socialstart = '<div id="header-container">';
            $class_header2_socialend = '</div>';
            $class_header2_socialshow = '1';
        }
    }
    ?>
		<div id="header">
		<div id="header-core">

			<?php 
    echo $class_header2_socialstart;
    ?>

			<div id="logo">
			<a rel="home" href="<?php 
    echo esc_url(home_url('/'));
    ?>
"><?php 
    /* Custom Logo */
    thinkup_custom_logo();
    ?>
</a>
			</div>

			<?php 
    echo $class_header2_socialend;
    ?>

			<div id="header-links" class="main-navigation">
			<div id="header-links-inner" class="header-links">

				<?php 
    $walker = new thinkup_menudescription();
    wp_nav_menu(array('container' => false, 'theme_location' => 'header_menu', 'walker' => new thinkup_menudescription()));
    ?>
				
				<?php 
    /* Header Search */
    thinkup_input_headersearch();
    ?>

			</div>
			</div>
			<!-- #header-links .main-navigation -->
 	
			<?php 
    /* Add responsive header menu */
    thinkup_input_responsivehtml1();
    ?>

		</div>
		</div>
		<!-- #header -->
<?php 
}
コード例 #2
0
$walker = new thinkup_menudescription();
wp_nav_menu(array('container' => false, 'theme_location' => 'header_menu', 'walker' => new thinkup_menudescription()));
?>
				
				<?php 
/* Header Search */
thinkup_input_headersearch();
?>

			</div>
			</div>
			<!-- #header-links .main-navigation -->
 	
			<?php 
/* Add responsive header menu */
thinkup_input_responsivehtml1();
?>

		</div>
		</div>
		<!-- #header -->

		<?php 
/* Add responsive header menu */
thinkup_input_responsivehtml2();
?>

		<?php 
/* Custom Slider */
thinkup_input_sliderhome();
?>