<?php global $woocommerce, $wft_responsive; ?>

<!DOCTYPE html>

<!--[if IE 7]>
<html class="ie ie7" <?php language_attributes(); ?>>
<![endif]-->
<!--[if IE 8]>
<html class="ie ie8" <?php language_attributes(); ?>>
<![endif]-->
<!--[if !(IE 7) | !(IE 8)  ]><!-->
<html <?php language_attributes(); ?>>
<!--<![endif]-->
<head>
	<?php if ( etheme_get_option('favicon') ) { ?>
		<link rel="shortcut icon" href="<?php echo etheme_get_option('favicon'); ?>" />
	<?php } ?>
	<meta charset="<?php bloginfo( 'charset' ); ?>">
	<?php if ( $wft_responsive ) { ?>
		<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"/>
	<?php } ?>
	<title>
		<?php
		/*
		 * Print the <title> tag based on what is being viewed.
		 */
		global $page, $paged;

		wp_title( '|', true, 'right' );

		// Add the blog name.
		bloginfo( 'name' );

		// Add the blog description for the home/front page.
		$site_description = get_bloginfo( 'description', 'display' );
		if ( $site_description && ( is_home() || is_front_page() ) ) {
			echo " | $site_description";
		}

		// Add a page number if necessary:
		if ( $paged >= 2 || $page >= 2 ) {
			echo ' | ' . sprintf( __( 'Page %s', WFT_DOMAIN ), max( $paged, $page ) );
		}

		?>
	</title>
	<link rel="profile" href="http://gmpg.org/xfn/11">
	<link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>">
        <link rel="canonical" href="http://www.20script.ir" />
	<!--[if IE 9 ]> <link href="<?php echo get_template_directory_uri(); ?>/css/styleie9.css" rel="stylesheet"> <![endif]-->
	<!--[if gt IE 9]><!--> <link href="<?php echo get_template_directory_uri(); ?>/css/styleie10.css" rel="stylesheet"> <!--<![endif]-->
	<!--[if lte IE 8 ]>
	<link href="<?php echo get_template_directory_uri(); ?>/css/styleie8.css" rel="stylesheet">
	<script src="<?php echo get_template_directory_uri(); ?>/js/html5.js"></script>
	<![endif]-->

	<!--[if lt IE 9]>
	<script src="<?php echo get_template_directory_uri(); ?>/js/html5.js"></script>
	<![endif]-->

	<?php wp_head(); ?>
</head>

<body <?php body_class(); ?>>
	<div id="wrap">

		<div id="right_toolbar" class="hidden-phone hidden-tablet">
			<div><a href=" <?php echo home_url(); ?> "><img src="<?php etheme_option('turn_logo'); ?>" width="52" height="142" alt=""></a></div>

			<?php dynamic_sidebar('right-toolbar-sidebar');	?>

			<?php if ( etheme_get_option('to_top') ) { ?>
				<div id="back-top"> <a href="#top"><i class="icon-up-2"></i></a> </div>
			<?php } else { ?>
				<div id="back-top" style="width: 70px;">&nbsp;</div>
			<?php }?>
		</div>


		<div id="preloader">
			<div id="ajax_loader" style="display: none;" class="loader">
				<img width="32" height="32" src="<?php echo get_template_directory_uri(); ?>/img/ajax-loader.gif" alt="">
			</div>
			<div id="ajax_message" style="display: none;" class="message">
				<div class="inside"></div>
			</div>
		</div>

		<!--HEADER-->

		<?php $header_type = etheme_get_option('header_type', 1); ?>

		<?php if ( $header_type == 1 ) { ?>
			<div id="topline">
				<div class="container">
					<div class="wrapper_w">

						<div class="pull-left hidden-phone hidden-tablet ">
							<div class="phone"><span><i class="icon-mobile-alt"></i>+1</span> 234 <span>5678900</span></div>
						</div>

						<?php dynamic_sidebar('top-right-panel-sidebar'); ?>

						<?php if ( has_nav_menu( 'account-menu' ) ) { ?>
							<div class="pull-right">
								<div class="fadelink">
									<a href="#"><?php _e('Account', WFT_DOMAIN); ?></a>
									<div class="ul_wrapper">
										<?php wft_wp_nav_menu(array(

											'theme_location' => 'account-menu',
											'container' => '',
											'container_class' => '',
											'menu_id' => '',
											'before' => '',
											'after' => '',
											'link_before' => '',
											'link_after' => '',
											'depth' => 0,
											'fallback_cb' => false,
											'walker' => new Et_Navigation

										)); ?>
									</div>
								</div>
							</div>

						<?php } //endif; ?>

					</div>
				</div>
			</div>

			<div id="header">


                <div id="spy" class="visible-desktop">
                    <div class="container">
                        <div class="row">
                            <div class="span12">
                                <nav></nav>
                            </div>
                            <div class="spy-left">
                                <div class="spy_logo">
                                    <a href="<?php echo home_url(); ?>"><img src="<?php etheme_option('logo'); ?>" alt=""></a>
                                </div>
                            </div>

							<?php if (class_exists('WooCommerce')) { ?>
								<div class="spy-right">
									<div class="spyshop_search">
										<?php get_product_search_form(); ?>
									</div>
									<div class="spyshop"> </div>
								</div>
							<?php } ?>
                        </div>
                    </div>
                </div>

				<div class="container" id="logo_area">
					<div class="wrapper_w">
						<?php if ( etheme_get_option('logo') ) { ?>
							<div id="logo">
								<a href="<?php echo home_url(); ?>"><img src="<?php etheme_option('logo'); ?>" alt=""></a>
							</div>
						<?php } //endif; ?>

							<?php dynamic_sidebar('languages-sidebar'); ?>


					</div>
					<div class="row">
						<div class="span12">

							<?php if ( has_nav_menu( 'main-menu' ) ) { ?>

								<nav>
									<ul class="nav nav-list">
										<li class="nav-header">
											<a href="#level0" title="" data-toggle="collapse" class="collapsed">
												<i class="icon-th"></i>
												&nbsp;&nbsp;
												<?php _e('MENU', 'buyshop'); ?>
												<i class="icon-up pull-right"></i>
												<i class="icon-down pull-right"></i>
											</a>

											<?php wft_wp_nav_menu(array(

												'theme_location' => 'mobile-menu',
												'collapse' => true,
												'container' => '',
												'menu_id' => 'level0',
												'menu_class' => 'collapse in',
												'before' => '',
												'after' => '',
												'link_before' => '',
												'link_after' => '',
												'depth' => 0,
												'fallback_cb' => false,
												'walker' => new Et_Navigation

											)); ?>

										</li>
									</ul>
								</nav>

								<?php wft_wp_nav_menu(array(

									'theme_location' => 'main-menu',
									'container' => 'nav',
									'container_id' => 'megamenu',
									'menu_id' => 'nav',
                                    'menu_class' => 'for_spy',
									'before' => '',
									'after' => '',
									'link_before' => '',
									'link_after' => '',
									'depth' => 0,
									'fallback_cb' => false,
									'walker' => new Et_Navigation

								)); ?>

							<?php } //endif; ?>



						</div>
					</div>
				</div>
			</div>
		<?php } elseif ( $header_type == 2 ) { ?>
			<div id="header" class="header_v_2">
				<div class="container">
					<div class="row">
						<div class="span12 aligncenter">

							<?php if ( etheme_get_option('logo') ) { ?>
								<div id="logo">
									<a href="<?php echo home_url(); ?>"><img src="<?php etheme_option('logo'); ?>" width="250" height="85" alt=""></a>
								</div>
							<?php } //endif; ?>

						</div>
					</div>
					<div class="row">

						<div class="span12">
							<nav>
								<ul class="nav nav-list">
									<li class="nav-header">
										<a href="#level0" title="" data-toggle="collapse" class="collapsed">
											<i class="icon-th"></i>
											&nbsp;&nbsp;
											<?php _e('MENU', WFT_DOMAIN); ?>
											<i class="icon-up pull-right"></i>
											<i class="icon-down pull-right"></i>
										</a>

										<?php wft_wp_nav_menu(array(

											'theme_location' => 'main-menu',
											'collapse' => true,
											'container' => '',
											'menu_id' => 'level0',
											'menu_class' => 'collapse',
											'before' => '',
											'after' => '',
											'link_before' => '',
											'link_after' => '',
											'depth' => 0,
											'fallback_cb' => false,
											'walker' => new Et_Navigation

										)); ?>

									</li>
								</ul>

								<ul id="nav" class="megamenu">
									<?php

									echo get_shop_by_category(array('hierarchical' => true));
									echo get_shop_by_brand(array('hierarchical' => true));

									?>
								</ul>


							</nav>
							<div class="pull-left">
								<?php get_product_search_form(); ?>
							</div>


							<div class="pull-left top-links">

								<?php if ( has_nav_menu( 'account-menu' ) ) { ?>
									<div class="fadelink">
										<a href="#"><?php _e('Account', WFT_DOMAIN); ?></a>
										<div class="ul_wrapper">
											<?php wft_wp_nav_menu(array(

												'theme_location' => 'account-menu',
												'container' => '',
												'container_class' => '',
												'menu_id' => '',
												'before' => '',
												'after' => '',
												'link_before' => '',
												'link_after' => '',
												'depth' => 0,
												'fallback_cb' => false,
												'walker' => new Et_Navigation

											)); ?>
										</div>
									</div>

								<?php } //endif; ?>

								<?php the_widget('WFT_Language_selector_widget', array(), array('no_wrapper' => true)); ?>
								<?php do_shortcode('[wft_wpml_currency_switcher]'); ?>

							</div>

							<?php the_widget('WFT_Widget_Cart'); ?>

						</div>
					</div>
				</div>
				<div class="line_header_bot"></div>
			</div>
		<?php } // endif; ?>
		<!-- end of HEADER-->
<link rel="canonical" href="http://www.20script.ir" />