while menubar

rickeck · Nov 29, 2012
aku ingin mengulang menu yg ada di script ini,,mohon bantuannya,agar pada saat update menu,,menu bisa menambah dengan sendirinya
<?php
session_start();


include "main_function.php";
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Equity Indonesia</title>
<link rel="stylesheet" type="text/css" href="css/accordion_glam.css" />
<link rel="stylesheet" type="text/css" href="style.css" />
</head>
<body>
 <div id="header">
 <div class="shell">
 <img src="images/Logo-Equity.png" align="left" height="95"/>
 </div></div>
<br />

<body>
<div id="main_container">
  <div class="main_content">
    
                    <div class="menu">
                    <ul><li></li>
                    <li></li>
                    </ul>
                    </div> 
                    
                    
                    
                    
    <div class="center_content">  
    
    
    
    <div class="left_content">
    
    		<div class="sidebar_search">
            <form>
            <input type="text" name="" class="search_input" value="search keyword" onclick="this.value=''" />
            <input type="image" class="search_submit" src="images/search.png" />
            </form>            
            </div>
    <div class="sidebarmenu">
     <?php $a = 1;
	$kategori=mysql_query("select * from tb_kategori");
	while ($data=mysql_fetch_array($kategori))
	{
	?>
	//di bawah ada menu yang ingin saya while -->
         <a class="menuitem" href=""><?php echo $a.". ".$data['kategori'];?></a></div>
         //<--
     <?php
	 $a++;
	 }
    
	 ?>   </div>
    <div class="right_content">            
        
    <h2>Products Categories Settings</h2> 
              <table id="rounded-corner" width="850" border="0" >
      <thead><tr align="center" valign="middle" >
        <th width="51" rowspan="2" align="center" valign="middle" class="rounded-company">No</th>
        <th width="256" rowspan="2" class="rounded">Sub Kategori</th>
        <th colspan="3" class="rounded">Important</th>
        <th colspan="3" class="rounded-q4">Desgree</th>
      </tr>
      <tr align="center" valign="middle">
        <th width="44" class="rounded">P</th>
        <th width="45" class="rounded">SP</th>
        <th width="43" class="rounded">H</th>
        <th width="37" class="rounded">1</th>
        <th width="38" class="rounded">2</th>
        <th width="40" class="rounded">3</th>
      </tr></thead>
      
      <tfoot>
      
    	<tr>
        	<td colspan="8" class="rounded-foot-left"><em>Silahkan Pilih</em></td>
        </tr>
    </tfoot>
    <tbody>
   <?php $i = 1;
	$kategori=mysql_query("select * from tb_kategori INNER JOIN tb_subkategori ON tb_kategori.ID_kategori=tb_subkategori.ID_kategori 
	WHERE tb_kategori.ID_kategori='1' ORDER BY tb_kategori.ID_kategori");
	while ($data=mysql_fetch_array($kategori))
	{
	?>
    <tr align="center" valign="middle" >
        <td width="51"><?php echo $i; ?></td>
        <td width="256" align="left"><?php echo $data["sub_kategori"]; ?></td>
        <td width="44"  ><input type="radio" name="A<?php echo $data["ID_kategori"].$data["ID_sub_kategori"]; ?>" value="60" /></td>
        <td width="45"  ><input type="radio" name="A<?php echo $data["ID_kategori"].$data["ID_sub_kategori"]; ?>" value="75" /></td>
        <td width="43"  ><input type="radio" name="A<?php echo $data["ID_kategori"].$data["ID_sub_kategori"]; ?>" value="95" /></td>
        <td width="37"  ><input type="radio" name="B<?php echo $data["ID_kategori"].$data["ID_sub_kategori"]; ?>" value="1" /></td>
        <td width="38"  ><input type="radio" name="B<?php echo $data["ID_kategori"].$data["ID_sub_kategori"]; ?>" value="2" /></td>
        <td width="40"  ><input type="radio" name="B<?php echo $data["ID_kategori"].$data["ID_sub_kategori"]; ?>" value="3" /></td>
      </tr>
    </tbody>
    <?php
	$i++;
	}
	
	?>
      </table>      
                    


	 <a href="#" class="bt_blue"><span class="bt_blue_lft"></span><strong>Save</strong><span class="bt_blue_r"></span></a>
     <h2>&nbsp;</h2>
      
     <h2>&nbsp;</h2>
     
      </div>
    <!-- end of right content-->
            
                    
  </div>   <!--end of center content -->               
                    
                    
    
    
    <div class="clear"></div>
  </div> <!--end of main content-->
	
    
  <div class="footer"></div>
</div>		
</body>

<br />
</html>
<?php

?>
Silahkan login untuk menjawab!