<!DOCTYPE html>
<!--[if lt IE 7]>      <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]-->
<!--[if IE 7]>         <html class="no-js lt-ie9 lt-ie8"> <![endif]-->
<!--[if IE 8]>         <html class="no-js lt-ie9"> <![endif]-->
<!--[if gt IE 8]><!--> <html xmlns="http://www.w3.org/1999/xhtml" xmlns:fb="http://www.facebook.com/2008/fbml" class="no-js" ng-app="myapp"> <!--<![endif]--><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>{if $title|default:''!=''}{$title}{else}{$commonSiteName}{/if}</title>
<meta name="Description" content="{$commonMetaDescription}" />
<meta name="viewport" content="width=device-width">
<meta name="Keywords" content="{$commonMetaKeywords}" />
{include file='CommonStyles.tpl'}
{include file='CommonJavaScript.tpl'}
</head>
<body ng-controller="SearchCtrl"> 

<!-- Begin : Outer Pane -->
<div id="main"> 
  <!-- Begin : Header Pane--> 
  {include file='CommonTop.tpl'} 
		
         
  <div id="content-wrapper" ng-show="!query"> 
    
    <!-- Begin : Content Pane -->
    <div class="container clearfix">
	<h1 class="h2-style">{$language.lblAllCategories}</h1>
	<div id="common_message" ></div>
    <div class="light-bg menu pos-rel margin-bottom">
	      <ul  class="category-list">
		{* define the function *} 
		{function name=Allcategories level=0}
			{foreach from=$data item="productCategory"} 
				<li>
				
					{if $level==1}
						{html->anchor href="{$productCategory.productCategoryID|sef_path:'catalog'}" content="<strong>{$productCategory.productCategoryName}</strong>"}
					{else}
						{html->anchor href="/{$productCategory.productCategoryID|sef_path:'catalog'}" content="{$productCategory.productCategoryName}"}
					{/if}
				{if isset($productCategory['children']) && is_array($productCategory['children']) && !empty($productCategory['children'])}
					{assign var="elementCount" value=$productCategory['children']|count/3}
					{assign var="elementCount" value=$elementCount|ceil}
					{if $elementCount>0}
						{if $level<1}
						<div class=" grand_sub_menu  clearfix">
						{/if}
							{assign var="productCategoryChildren" value=array_chunk($productCategory['children'], 3)}
							{for $counter=0; $counter<$elementCount ; $counter++}
							<ul class="clearfix"> 
							{call name=Allcategories data=$productCategoryChildren[$counter] level=$level+1} 
							</ul>
							{/for}
						{if $level<1}
						</div>
						{/if}
					{else}
						<ul > 
						{call name=Allcategories data=$productCategory['children'] level=$level+1} 
						</ul>
					{/if}
				{else}
					{if (is_array($productCategory)) && (isset($productCategory['menuItemID'])) && (is_numeric($productCategory['menuItemID']))}
					</li>	
					{/if}
				{/if}
			{/foreach}  
		{/function}
		{call Allcategories data=$CategoryMenus} 
	</ul>
    </div>

    </div>
    <!-- End : Content Pane --> 
    
  </div>
  <!-- Begin : Footer	Pane --> 
  {include file='CommonBottom.tpl'} 
  <!-- End : Footer Pane --> 
</div>
<!-- End : Outer Pane --> 
</body>
{include file='CommonJavaScriptBottom.tpl'  }
</html>