ini_set('display_errors','on'); function total_sub_menu1($table,$cond) { global $dbh; $sqlopt="select menu_id from $table where 1=1 $cond "; $rs1=mysqli_query($dbh,$sqlopt); $tot1=mysqli_num_rows($rs1); return $tot1; } class menu { var $indent=0; var $menulist=""; var $indent_text="- "; var $menu_str=""; function getCategoryList($parent_id) { global $dbh; $sql_headers="select * from cms_multimenu_top where parent_id='".$parent_id."'"; $res_menu=mysqli_query($dbh,$sql_headers); if($res_menu && mysqli_num_rows($res_menu)) { while($row=mysqli_fetch_array($res_menu,MYSQLI_BOTH)) { $add_indent=""; for($i=0; $i< $this->indent; $i++) $add_indent.=$this->indent_text; $menu_id=$row['menu_id']; $menu_name=$row['menu_name']; $this->menulist.='\n"; $this->indent++; $parent_id=$menu_id; $this->getCategoryList($parent_id); } } $this->indent--; if($this->indent<0) { $val=$this->menulist; $this->menulist=""; $this->indent=0; return $val; } } function showCategoryList($parent_id=0,$fieldname='',$showtop="",$currid="",$size=10) { global $dbh; $str=''; if($fieldname!='') { $str=''; } return $str; } function showCategoryTopMenu($parent_id=0) { $str.=$this->getCategoryTopMenu($parent_id); return $str; } function getTopMenu($parent_id) { global $dbh; global $SA_SITEURL; $i=0; $cls=$cls2=""; $aurl="";$s1=$s2=$s3=""; $sql_headers="select * from cms_multimenu_top where parent_id='".$parent_id."' and active_status=1 order by menu_order"; $res_menu=mysqli_query($dbh,$sql_headers); $countCAt=mysqli_num_rows($res_menu); if($parent_id==0){ $cls="class='menuu'"; $aurl="" ; $s1=$s2=$s3=""; $aurl=""; }else{ $cls="class=' '"; $aurl="itemprop='url'" ; $s1=""; $s2=""; $s3=""; } if($res_menu && mysqli_num_rows($res_menu)) { $this->menu_str.="