I have did some code but now i want to add sub categories in my main category but now i want when admin click on any option the page will automatically refresh because below this i have a sub category option when it will refresh the page then my particular subcategories will appear i hope if you guys have any suggestion then please suggest me.
<select name="cat">
<option value='null'>Select your Desire</option>
<?php
include('includes/db.php');
$c_query="select * from categories";
$c_run=(mysql_query($c_query));
while($c_row=mysql_fetch_array($c_run)){
$c_id=$c_row['p_id'];
$c_title=$c_row['p_title'];
echo "<option value='$c_id'>$c_title</option>";
}
?>
</select>