Monkey Albino

Linux altar53.supremepanel53.com 4.18.0-553.8.1.lve.el8.x86_64 #1 SMP Thu Jul 4 16:24:39 UTC 2024 x86_64
/ home/ bdapparelinfo/ aifatradebd.com/ Wp-Administrator/

/home/bdapparelinfo/aifatradebd.com/Wp-Administrator/View_Cat.php

<?php 	
	  $dis_pages = $function_file->view_pages();
	//////////////////////		
	$tableName="menu";		
	if(isset($_POST['srch_user'])){	
				$us=$_POST['key'];
	$result =$sql_cat=mysql_query("SELECT * FROM `$tableName` WHERE position ='$us' ORDER BY `sir_no` DESC");
		/* echo $asc_desc ;	exit; */  
 		}else{
	$result =$sql_cat=mysql_query("SELECT * FROM `$tableName` WHERE `parents_cat_id`='0' ORDER BY `id` ASC");
		}
 $msg=$_GET['msg'];
 
 //////////delete function all
 $DelID=$_GET['del_id']; 
 if($DelID){
	///echo $DelID;	exit();
	$del_pages = $function_file->delete_cat_id($DelID);
	if(file_exists($file)){unlink($file);}
	}
	$result_row=mysql_query("SELECT * FROM `menu`");
	$count=mysql_num_rows($result);
 	$delete=$_POST['delete']; 

if($delete){$checkbox=$_POST['checkbox']; 
	for($w=0;$w<$count;$w++){
	$DelID = $checkbox[$w];
	$dell_all_row=mysql_fetch_array(mysql_query("SELECT * FROM `menu` WHERE id='$DelID'")); 
	 
	$del_pages = $function_file->delete_cat_id($DelID);
	}
	 
}
?>
         <table align="left" border="0" cellpadding="0" cellspacing="0" width="995">
                     <tbody><tr>
                         <td valign="top">
                <!--end validation-->		
<script type="text/javascript">

function confirmUnpublish()
{
    return confirm("Are you sure you want to Delete this ?");
}
 /////////////////////////////checkbox select option
$(function(){
 
    // add multiple select / deselect functionality
    $("#selectall").click(function () {
          $('.case').attr('checked', this.checked);
    });
 
    // if all checkbox are selected, check the selectall checkbox
    // and viceversa
    $(".case").click(function(){
 
        if($(".case").length == $(".case:checked").length) {
            $("#selectall").attr("checked", "checked");
        } else {
            $("#selectall").removeAttr("checked");
        }
 
    });
});
</SCRIPT>
<table align="left" border="0" cellpadding="0" cellspacing="0" width="995">
            
            <tbody><tr>
                <td valign="top"><br><h1 style="color:#2d2d2d;">Menu Management</h1><br>
				<?php if($msg=='3'){echo"Delete Success";} ?>
				</td>
            </tr>

            <tr>
                <td valign="top">
                   <table class="user-table" style="background-color: rgb(255, 255, 255);" align="center" border="0" cellpadding="0" cellspacing="2" width="895px">
                        <tbody><tr>                                                                         
                            <td style="background-color: rgb(229, 229, 229); border-bottom: 1px solid rgb(204, 204, 204); padding-left: 10px; color: rgb(0, 0, 0);" height="30">
                            <h2><a href="dashboard.php?cid=ins_Categories"><img src="images/icon-16-user-dd.png" border="0"> Add New Menu</a>                            </h2>
                            </td>
                        </tr>
    
                        <tr>                                                                         
                            <td>
                                                                <!--user view st-->
                                <table align="center" border="0" cellpadding="0" cellspacing="20" width="995">
                                                                        <!-- Unpublish -->
                                    <tbody>
				
                                    
                               
                                    <tr>
                                            <td>
                                                <div>&nbsp;&nbsp;<b>Page: </b>
                                                            
                                               </div>
                                            </td>
                                     </tr>
                                    <!--publish-->
                                    <tr>
                                        <td align="right" height="30">Publish [USER]</td>
                                    </tr>
                                    
                                    <tr>
                                        <td style="background-color: rgb(204, 204, 204);">
                                            <table align="center" border="0" cellpadding="1" cellspacing="1" width="100%">
                                                <form action="" method="post" onsubmit="return smVali();" enctype="multipart/form-data">
                                                <tbody>
                                                <tr style="background-color: rgb(231, 231, 231); height: 25px;">
                                                    <td width="25"> </td>
                                                    <td><select class="regi-submit" name="key" id="key">
														   <option value="Menu Bar"> Menu Bar</option> 
														   <option value="Right Bar"> Right Bar</option> 
														   <option value="Home Body"> Home Body</option> 
														   <option value="Header Bar"> Header Bar</option> 
                                            			</select>
													</td>
                                                    <td><input type="submit" name="srch_user"  class="btn btn-primary" value="Search"></td>
                                                    <td width="38" colspan="2" align="right"><!--<input name="delete" type="submit" id="delete" class="btn btn-primary"  value="Delete All" onClick="return confirmUnpublish();">--> </td>
                                                    <td width="48">&nbsp; <!--<input type="checkbox" id="selectall"/> --> </td>
                                                 </tr>
                                                <tr style="background-color: rgb(231, 231, 231); height: 25px;">
                                                    <td><b>ID</b></td>
                                                    <td>&nbsp;<b>Menu Name</b></td>
                                                    <td width="318">&nbsp;<b>Position</b></td>
                                                    <td>&nbsp;<b>Serial </b></td>
                                                    <td colspan="2">&nbsp;<b>Action</b></td>
                                                </tr>
												<?php $x=1;while($display_cat=mysql_fetch_array($result)){$C_Id=$display_cat['id'];
															$sql_sub_cat=mysql_query("SELECT * FROM `menu` WHERE `parents_cat_id`='$C_Id' ORDER BY `id` ASC");
												?>
                                              <tr style="background-color: rgb(255, 255, 255);">
                                                        <td><?=$x++;?></td>
                                                        <td width="238"><?=$display_cat['cat_name'];?></td>
                                                        <td><?=$display_cat['position'];?></td>
                                                        <td><?=$display_cat['sir_no'];?></td>
                                                        <td width="38"><a href="dashboard.php?cid=ins_Categories&id=<?=$C_Id;?>" title="Edit Content">Edit</a></td>
                                                        <td width="48">&nbsp; <!--<input name="checkbox[]" class="case" type="checkbox" value="<?=$C_Id;?>"> <br />  <br /> -->
														<a onClick="return confirmUnpublish();" href="dashboard.php?cid=<?=$Cat;?>&del_id=<?=$C_Id;?>">Delete </a></td>
                                                  </tr>
												  	 <?php while($row_sub=mysql_fetch_array($sql_sub_cat)){$Sub_C_Id=$row_sub['id'];
															$sub_sub_cat=mysql_query("SELECT * FROM `menu` WHERE `parents_cat_id`='$Sub_C_Id' ORDER BY `id` ASC");
													?> 
													 		
                                              <tr style="background-color: rgb(255, 255, 255);">
                                                        <td><?=$x++;?></td>
                                                        <td width="238"> -<?=$row_sub['cat_name'];?></td>
                                                        <td><?=$row_sub['position'];?></td>
                                                        <td><?=$row_sub['sir_no'];?></td>
                                                        <td width="38"><a href="dashboard.php?cid=ins_Categories&id=<?=$Sub_C_Id;?>" title="Edit Content">Edit</a></td>
                                                        <td width="48">&nbsp; <!--<input name="checkbox[]" class="case" type="checkbox" value="<?=$Sub_C_Id;?>"> <br />  <br /> -->
														<a onClick="return confirmUnpublish();" href="dashboard.php?cid=<?=$Cat;?>&del_id=<?=$Sub_C_Id;?>">Delete </a></td>
                                                  </tr>
												  	 <?php while($row_3rdsub=mysql_fetch_array($sub_sub_cat)){$Sub_3rdC_Id=$row_3rdsub['id'];?> 
													 		
                                              <tr style="background-color: rgb(255, 255, 255);">
                                                        <td><?=$x++;?></td>
                                                        <td width="238"> --<?=$row_3rdsub['cat_name'];?></td>
                                                        <td><?=$row_3rdsub['position'];?></td>
                                                        <td><?=$row_3rdsub['sir_no'];?></td>
                                                        <td width="38"><a href="dashboard.php?cid=ins_Categories&id=<?=$Sub_3rdC_Id;?>" title="Edit Content">Edit</a></td>
                                                        <td width="48">&nbsp; <!--<input name="checkbox[]" class="case" type="checkbox" value="<?=$Sub_3rdC_Id;?>"> <br />  <br /> -->
														<a onClick="return confirmUnpublish();" href="dashboard.php?cid=<?=$Cat;?>&del_id=<?=$Sub_3rdC_Id;?>">Delete </a></td>
                                                  </tr>
												<?php 		} 
													   } 
												  }?>
                                                </form>
                                                                                                                            
                                            </tbody></table>
                                        </td>                
                                    </tr>
							<tr> 
                                </tbody></table> 

 								<!--user view end-->
                            </td>
                        </tr>
                    </tbody></table>
                 </td>
             </tr>
</tbody></table>
    <script type="text/javascript">


      $( function () {
        
  twitter.screenNameKeyUp();
  $('#user_screen_name').focus();

      });
    

</script>

                 </td>
                     </tr>
                     
                     <tr>
                         <td>&nbsp;</td>
                     </tr>
         </tbody></table>
      </td>
      </tr>

      <tr>
           <td>&nbsp;</td>
           <td colspan="2"><table style="height: 1px; font-size: 1px;" align="center" border="0" cellpadding="0" cellspacing="0" width="100%">
    <tbody><tr>
    </tr>
</tbody></table>