
<?php if ( noo_get_option( 'noo_header_top_bar', false ) ) :
	$search_box = noo_get_option( 'noo_top_bar_search', true );
?>
<?php 
	$header_style   = noo_get_option('noo_header_nav_style','header1'); 
	if( is_page() ) {
		$header_page = noo_get_post_meta(get_the_ID(),'_noo_wp_page_header_style');
		if( !empty( $header_page ) && $header_page != 'header' ){
			$header_style = $header_page;
		}
	}
?>
	<?php if($header_style == 'header1') : ?>
		<div class="noo-topbar">
			<div class="topbar-inner container-boxed max">
				<div class="row">
					<div class="col-xs-12">
						<div class="topbar-left"><?php echo noo_get_option( 'noo_top_bar_content', '' ); ?></div>
					</div>
				</div>
			</div> <!-- /.topbar-inner -->
		</div> <!-- /.noo-topbar -->
	<?php elseif($header_style == 'header2'): ?>
		<div class="noo-topbar">
			<div class="topbar-inner container-boxed max">
				<div class="row">
					<div class="noo-topbar-left col-xs-6">
						<div class="topbar-left"><?php echo noo_get_option( 'noo_top_bar_content', '' ); ?></div>
					</div>
					<div class="noo-topbar-right col-xs-6">
						<?php if(noo_get_option( 'noo_header_member', true )) :?>
							<?php if( !is_user_logged_in() ) : ?>
								<ul class="sub-menu">
									<li><a href="<?php echo Noo_Member::get_register_url();?>" class="member-register-link"><i class="fa fa-key"></i> <?php _e('Register','noo')?></a></li>
									<li><a  href="<?php echo Noo_Member::get_login_url();?>" class="member-login-link"><i class="fa fa-sign-in"></i> <?php _e('Login','noo')?></a></li>
								</ul>
								<?php else : ?>
									<?php global $current_user;
										wp_get_current_user();
									?>
									<ul class="sub-menu">
										<?php if(defined('WOOCOMMERCE_VERSION')) : ?>
											<li><a href="<?php echo Noo_Member::get_manage_page_url()?>"><i class="fa fa-sign-out"></i> <?php _e('Manage Membership','noo')?></a></li>
										<?php endif;?>
										<li><a href="<?php echo Noo_Member::get_logout_url()?>"><i class="fa fa-sign-out"></i> <?php _e('Log out','noo')?></a></li>
									</ul>
								<?php endif;?>
						<?php endif ?>
					</div>
				</div>
			</div> <!-- /.topbar-inner -->
		</div> <!-- /.noo-topbar -->
	<?php endif; ?>
<?php endif; ?>
