<?php require_once("themes/".$GLOBALS['_CFG']['template']."/diyfile.php");?>
<script type="text/javascript">
var process_request = "<?php echo $this->_var['lang']['process_request']; ?>";
</script>
<div id="top">
  <div class="left"><a href="index.php"><img src="themes/yijun/images/logo.gif" border="0"/></a></div>
  <div class="right">
     <div class="topinfo">
           <?php echo $this->smarty_insert_scripts(array('files'=>'transport.js,utils.js')); ?>
        <span id="ECS_MEMBERZONE"><?php 
$k = array (
  'name' => 'member_info',
);
echo $this->_echash . $k['name'] . '|' . serialize($k) . $this->_echash;
?> </span>
       　<a class="snf8">|</a>　<img src="themes/yijun/images/ico1.gif" align="absmiddle"> <a href="message.php" class="snf1" target="_blank">在线客服</a>　<a class="snf8">|</a>　<img src="themes/yijun/images/ico2.gif" align="absmiddle"> <a href="user.php" class="snf1">我的帐户</a>　<a class="snf8">|</a>　<img src="themes/yijun/images/ico3.gif" align="absbottom"> <?php echo $this->smarty_insert_scripts(array('files'=>'transport.js')); ?>
    <span id="ECS_CARTINFO">
     <?php 
$k = array (
  'name' => 'cart_info',
);
echo $this->_echash . $k['name'] . '|' . serialize($k) . $this->_echash;
?>
    </span>
    </div>
      <div class="row">
        <div class="row1">
        <div class="row3"><div class="memberNum"><span class="snf4"><?php $this->assign('user_sum',get_user_sum()); ?><?php echo $this->_var['user_sum']; ?></span>位会员信赖的葡萄酒商城</div></div>
        <div class="row3"> <div class="home"><a href="index.php"><?php echo $this->_var['lang']['home']; ?></a></div>
          <div class="topbar"> <?php $_from = $this->_var['navigator_list']['middle']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }; $this->push_vars('', 'nav');$this->_foreach['nav_middle_list'] = array('total' => count($_from), 'iteration' => 0);
if ($this->_foreach['nav_middle_list']['total'] > 0):
    foreach ($_from AS $this->_var['nav']):
        $this->_foreach['nav_middle_list']['iteration']++;
?>
          <a href="<?php echo $this->_var['nav']['url']; ?>" <?php if ($this->_var['nav']['opennew'] == 1): ?>target="_blank" <?php endif; ?> lass="snf1"><?php echo $this->_var['nav']['name']; ?></a>
          <?php endforeach; endif; unset($_from); ?><?php $this->pop_vars();; ?>
          </div>
        </div>
        </div>
        <div class="row2"><div class="phone400"><img src="themes/yijun/images/400b.gif"></div><div class="mytealogo"><a href="#" target="_blank"><img src="themes/yijun/images/logo_mytea.gif" border="0"></a></div></div>
      </div>
  </div>
</div>
  <div class="menu">
    <ul>
		<?php $this->assign('categoriesmenu', get_categories_tree());?>
		<?php $_from = $this->_var['categoriesmenu']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }; $this->push_vars('', 'cat');$this->_foreach['cur'] = array('total' => count($_from), 'iteration' => 0);
if ($this->_foreach['cur']['total'] > 0):
    foreach ($_from AS $this->_var['cat']):
        $this->_foreach['cur']['iteration']++;
?>
		<?php if ($this->_foreach['cur']['iteration'] <= 4): ?>
		  <li><a onMouseOver="showDivList('Subto<?php echo $this->_foreach['cur']['iteration']; ?>')" onMouseOut="hideDivList('Subto<?php echo $this->_foreach['cur']['iteration']; ?>')" class="snf0"><?php echo htmlspecialchars($this->_var['cat']['name']); ?><img src="themes/yijun/images/ico4.gif" border="0" align="absmiddle" /></a>
			<div id="Subto<?php echo $this->_foreach['cur']['iteration']; ?>" onMouseOver="showDivList('Subto<?php echo $this->_foreach['cur']['iteration']; ?>')" onMouseOut="hideDivList('Subto<?php echo $this->_foreach['cur']['iteration']; ?>')">
			  <div class="Subtobox">
				<div class="r1"><a href="<?php echo $this->_var['cat']['url']; ?>" class="snf2"><?php echo htmlspecialchars($this->_var['cat']['name']); ?><img src="themes/yijun/images/ico5.gif" align="absmiddle"></a></div>
				<?php $_from = $this->_var['cat']['cat_id']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }; $this->push_vars('', 'child');$this->_foreach['cat'] = array('total' => count($_from), 'iteration' => 0);
if ($this->_foreach['cat']['total'] > 0):
    foreach ($_from AS $this->_var['child']):
        $this->_foreach['cat']['iteration']++;
?>
				<div class="r2"<?php if ($this->_foreach['cat']['iteration'] == 1): ?> style="border:0"<?php endif; ?>><a href="<?php echo $this->_var['child']['url']; ?>" class="snf1"><img src="themes/yijun/images/ico7.gif" align="absmiddle" ><?php echo htmlspecialchars($this->_var['child']['name']); ?></a></div>
				<?php endforeach; endif; unset($_from); ?><?php $this->pop_vars();; ?> 
			  </div>
			</div>
		  </li> 
		  <?php endif; ?> 
	   <?php endforeach; endif; unset($_from); ?><?php $this->pop_vars();; ?>
      <li style="width:90px;"><a class="snf0" href="message.php">留言板</a></li>
      <li style="width:100px;"><a class="snf0" href="article_cat.php?id=12">红酒生活</a></li>
      <li><a class="snf0" href="exchange.php">积分商城</a></li>
    </ul>
  </div>
    <div class="topsearch">
      <div class="searchs">
	   <script type="text/javascript">
    
    <!--
    function checkSearchForm()
    {
        if(document.getElementById('keyword').value)
        {
            return true;
        }
        else
        {
            alert("<?php echo $this->_var['lang']['no_keywords']; ?>");
            return false;
        }
    }
    -->
    
    </script>
  <form id="searchForm" name="searchForm" method="get" action="search.php" onSubmit="return checkSearchForm()">
    <div class="searchbox"><input type="text" name="keywords" id="keyword" onkeydown="searchingKeyWord(event.keyCode)" onBlur="if(this.value==''){this.style.background = 'url(images/keyword.gif) no-repeat #fff';} "onmousedown="if(this.value==''){this.style.background = '#FFF';focusval=true;}" value="" class="tsi" />
	<input name="imageField" type="image" value="" src="themes/yijun/images/searchmenu.gif" style="cursor:pointer;" class="go" />
	</div>
    <div class="hotbox">
    <?php if ($this->_var['searchkeywords']): ?>
   <?php echo $this->_var['lang']['hot_search']; ?> ：
   <?php $_from = $this->_var['searchkeywords']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }; $this->push_vars('', 'val');if (count($_from)):
    foreach ($_from AS $this->_var['val']):
?>
   <a class="snf1" href="search.php?keywords=<?php echo urlencode($this->_var['val']); ?>"><?php echo $this->_var['val']; ?></a>
   <?php endforeach; endif; unset($_from); ?><?php $this->pop_vars();; ?>
   <?php endif; ?>
   </div>
</form>
<script language="javascript">
	function showDivList(divname){
		document.getElementById(divname).style.display='block';
	}
	function hideDivList(divname){
		document.getElementById(divname).style.display='none';
	}
</script>
   </div>
</div>