<?php  
/*------------------------------------------------------------------------
# author    The Expert of itcenter in University of neyshabur
# copyright Copyright © 2011 neyshabur.ac.ir. All rights reserved.
# @license  http://www.gnu.org/licenses/gpl-2.0.html GNU/GPL
# Website   http://www.neyshabur.ac.ir
# طراحی توسط وحید دستجردی
-------------------------------------------------------------------------*/
defined( '_JEXEC' ) or die; 
// parameters (template)
$modernizr = $this->params->get('modernizr');
$pie = $this->params->get('pie');
$ganal = $this->params->get('ganal');
$webmaster = $this->params->get('webmaster');
$minify = $this->params->get('minify');
$minifymethod = $this->params->get('minifymethod');
$bodyfont = $this->params->get('bodyfont');
$headfont = $this->params->get('headfont');
$app = JFactory::getApplication();
$doc = JFactory::getDocument(); 
$params = $app->getParams();
$pageclass = $params->get('pageclass_sfx'); // parameter (menu entry)
$tpath = $this->baseurl.'/templates/'.$this->template;
$this->setGenerator(null);
// load sheets and scripts
$doc->addStyleSheet($tpath.'/css/template.css.php?dir='.$this->direction); 
if ($modernizr==1) $doc->addScript($tpath.'/js/modernizr-2.6.2.js'); // <- this script must be in the head
// unset scripts, put them into /js/template.js.php to minify http requests
unset($doc->_scripts[$this->baseurl.'/media/system/js/mootools-core.js']);
unset($doc->_scripts[$this->baseurl.'/media/system/js/core.js']);
unset($doc->_scripts[$this->baseurl.'/media/system/js/caption.js']);
?><!doctype html>
<!--[if IEMobile]><html class="iemobile" lang="<?php echo $this->language; ?>"> <![endif]-->
<!--[if IE 7]>    <html class="no-js ie7 oldie" lang="<?php echo $this->language; ?>"> <![endif]-->
<!--[if IE 8]>    <html class="no-js ie8 oldie" lang="<?php echo $this->language; ?>"> <![endif]-->
<!--[if gt IE 8]><!-->  <html class="no-js" lang="<?php echo $this->language; ?>"> <!--<![endif]-->
<head>
	<?php if($webmaster != 'HuAi5WX-88mduDM5U16adMcEPvRDtp2zuVkjmT') {?>
	    <meta name="google-site-verification" content="<?php echo $webmaster?>" />
    <?php } ?>
 <script type="text/javascript" src="<?php echo $tpath.'/js/template.js.php'; ?>"></script>
 <jdoc:include type="head" />
 <meta charset="utf-8">
 <meta http-equiv="X-UA-Compatible" content="IE=edge">
 <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" /> <!-- mobile viewport -->
 <link rel="manifest" href="<?php echo $tpath; ?>/manifest.json">
 <meta name="msapplication-TileColor" content="#ffffff">
 <meta name="msapplication-TileImage" content="<?php echo $tpath; ?>/ms-icon-144x144.png">
 <meta name="theme-color" content="#ffffff">
  <?php if ($pie==1) : ?>
    <!--[if lte IE 8]>
      <style> 
        {behavior:url(<?php echo $tpath; ?>/js/PIE.htc);}
      </style>
    <![endif]-->
  <?php endif; ?>
 <!--[if gte IE 9]>
  <style type="text/css">
    .gradient {
       filter: none;
    }
  </style>
<![endif]-->
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body class="<?php echo $pageclass; ?>">
<?php 
 if ($minify=='1'){
function ob_html_compress($buf){
//  return str_replace(array("\n","\r","\t"),'',$buf);
 	 return preg_replace(array('/<!--(.*)-->/Uis',"/[[:blank:]]+/"),array('',' '),str_replace(array("\n","\r","\t"),'',$buf)); 
}
ob_start("ob_html_compress");

 } // if minify
 ?>
 <div id="Main">
 <!---------------------------CODE GOES HERE ---------------------------------------------->
 <?php if ($this->direction == 'rtl'){ ?>
 <div class="container-fluid">		 
 <div class="row">		  
 <div class="hidden-xs col-sm-12 col-md-12 headerf"><jdoc:include type="modules" name="headerf" style="xhtml" />	</div><!--header--> 
 </div><!--row-->	
</div><!--container--> 	
		<div class="topf">		
   	    <div class="container-fluid">		 
             <div class="row">		  
                 <div class="hidden-xs col-sm-1 col-md-1 logof wow zoomIn"><jdoc:include type="modules" name="logof" style="xhtml" /></div><!--logo-->     
                 <div class="col-xs-12 col-sm-11 col-md-11 mmenuf">				 
                        <div class="row">	
				          <div class="col-xs-12 col-sm-12 col-md-12 topmenuf">
						     <div class="row">
						       <div class="col-xs-6 col-sm-6 col-md-6 searcherf" id="searchf"><jdoc:include type="modules" name="searcherf" style="xhtml" /></div><!--search-->
                               <div class="col-xs-4 col-sm-4 col-md-4 langmenuf" id="langf"><jdoc:include type="modules" name="langmenuf" style="xhtml" /></div><!--langmenu-->
							 </div><!--row-->	  
						  </div><!--topmenu-->	
						</div><!--row-->
						<div class="row">	
                          <div class="col-xs-10 col-sm-12 col-md-12 col-lg-12 mainmenuf"><jdoc:include type="modules" name="mainmenuf" style="xhtml" /></div><!--mainmenu-->
                          <div class="col-xs-2 hidden-sm hidden-md hidden-lg mainmenuimgf"><jdoc:include type="modules" name="logofimg" style="xhtml" /> </div><!--mainmenu-->						  
                        </div><!--row-->						  
				 </div><!--mmenu-->					
			 </div><!--row-->	
		</div><!--container--> 			
        </div><!--top-->  	
           <div class="container-fluid">		 
             <div class="row">				
      <div class="col-xs-12 col-sm-12 col-md-12 submenuf">
	       <div class="container">		 
             <div class="row">
			       <div class="col-xs-12 col-sm-12 col-md-12 submenumf"><jdoc:include type="modules" name="submenuf" style="xhtml" /></div><!--submenum-->
             </div><!--row-->	
		   </div><!--container--> 			 	  
	  </div><!--submenu-->
	  </div><!--row-->	
		   </div><!--container--> 
	  <div class="container">		 
       <div class="row">
         <div class="col-xs-12 col-sm-12 col-md-12 content" id="cn">
          <jdoc:include type="message" />
          <jdoc:include type="component" />
         </div><!--content--> 	
       </div><!--row-->	
      </div><!--container--> 
 <div class="container-fluid">		 
    <div class="row">	  
     <div class="bottomf"> 
     <div class="container">	 
       <div class="row">	 
          <div class="col-xs-12 col-sm-12 col-md-12 addressf"><jdoc:include type="modules" name="addressf" style="xhtml" /></div><!--address-->    
       </div><!--row-->	
 </div><!--container--> 
<div class="container">	  
          <div class="row" id="bottom2f">
             <div class="col-xs-12 col-sm-6 col-md-6 col-lg-6 snf"><jdoc:include type="modules" name="snf" style="xhtml" /></div><!--sn-->			 
             <div class="col-xs-12 col-sm-6 col-md-6 col-lg-6 copyrightf"><jdoc:include type="modules" name="copyrightf" style="xhtml" /></div><!--copyright--> 
         </div><!--row-->	
		 </div><!--container--> 
      </div><!--bottom--> 
    </div><!--row-->	
      </div><!--container--> 	  
 <?php }else{?>
 <div class="container-fluid">		 
 <div class="row">		  
 <div class="hidden-xs col-sm-12 col-md-12 header"><jdoc:include type="modules" name="header" style="xhtml" />	</div><!--header--> 
 </div><!--row-->	
</div><!--container--> 	
		<div class="top">		
   	    <div class="container-fluid">		 
             <div class="row">		  
                 <div class="hidden-xs col-sm-1 col-md-1 logo wow zoomIn"><jdoc:include type="modules" name="logoe" style="xhtml" /></div><!--logo-->     
                 <div class="col-xs-12 col-sm-11 col-md-11 mmenu">				 
                        <div class="row">	
				          <div class="col-xs-12 col-sm-12 col-md-12 topmenu">
						     <div class="row">
						       <div class="col-xs-6 col-sm-6 col-md-6 searcher" id="searche"><jdoc:include type="modules" name="searcher" style="xhtml" /></div><!--search-->
                               <div class="col-xs-4 col-sm-4 col-md-4 langmenu" id="lang"><jdoc:include type="modules" name="langmenu" style="xhtml" /></div><!--langmenu-->
							 </div><!--row-->	  
						  </div><!--topmenu-->	
						</div><!--row-->
						<div class="row">	
                          <div class="col-xs-10 col-sm-12 col-md-12 col-lg-12 mainmenu"><jdoc:include type="modules" name="mainmenu" style="xhtml" /></div><!--mainmenu-->
                          <div class="col-xs-2 hidden-sm hidden-md hidden-lg mainmenuimg"><jdoc:include type="modules" name="logoeimg" style="xhtml" /> </div><!--mainmenu-->						  
                        </div><!--row-->						  
				 </div><!--mmenu-->					
			 </div><!--row-->	
		</div><!--container--> 			
        </div><!--top-->  	
           <div class="container-fluid">		 
             <div class="row">				
      <div class="col-xs-12 col-sm-12 col-md-12 submenu">
	       <div class="container">		 
             <div class="row">
			       <div class="col-xs-12 col-sm-12 col-md-12 submenum"><jdoc:include type="modules" name="submenu" style="xhtml" /></div><!--submenum-->
             </div><!--row-->	
		   </div><!--container--> 			 	  
	  </div><!--submenu-->
	  </div><!--row-->	
		   </div><!--container--> 
	  <div class="container">		 
       <div class="row">
         <div class="col-xs-12 col-sm-12 col-md-12 content">
          <jdoc:include type="message" />
          <jdoc:include type="component" />
         </div><!--content--> 	
       </div><!--row-->	
      </div><!--container--> 
 <div class="container-fluid">		 
    <div class="row">	  
     <div class="bottom"> 
     <div class="container">	 
       <div class="row">	 
          <div class="col-xs-12 col-sm-12 col-md-12 address"><jdoc:include type="modules" name="address" style="xhtml" /></div><!--address-->    
       </div><!--row-->	
 </div><!--container--> 
<div class="container">	  
          <div class="row" id="bottom2">
             <div class="col-xs-12 col-sm-6 col-md-6 col-lg-6 sn"><jdoc:include type="modules" name="sn" style="xhtml" /></div><!--sn-->
             <div class="col-xs-12 col-sm-6 col-md-6 col-lg-6 copyright"><jdoc:include type="modules" name="copyright" style="xhtml" /></div><!--copyright--> 
         </div><!--row-->	
		 </div><!--container--> 
      </div><!--bottom--> 
    </div><!--row-->	
      </div><!--container--> 	  
    <?php } ?>
 
 
 <!---------------------------CODE GOES HERE ---------------------------------------------->
 </div><!--Main-->
  <?php
 if ($this->direction == 'rtl'){
 include_once('font.php');}
 else{
	include_once('fonte.php'); 
 }
 if ($minify=='1'){
	  ob_end_flush();
 }
?>
 <?php if ($ganal != 'UA-'): ?>
 <script>   (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){   (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),   m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)   })(window,document,'script','//www.google-analytics.com/analytics.js','ga');    ga('create', '<?php echo $ganal?>', 'auto');   ga('send', 'pageview');  </script>
 <?php endif;  ?>
</body>
</html>

