I have created one table into the database named Category_Table and another table named CategoryTitle.
for e.x.
1.Graphics and Animation(From Category_Table)
1.Concept Artist(From CategoryTitle Table)
2.Animator
3.Stereographer
4.Compositor
2.Sound
1.Sound Assistant
2.Sound Engineer
So what i am doing here is m calling these values from the database in a checkbox.
Expand|Select|Wrap|Line Numbers
- while($category_id <= 30)
- {
- $result = mysql_query("SELECT * FROM category_tbl where category_id = $category_id ");
- $row = mysql_fetch_assoc($result);
- echo '<div id="main">';
- echo '<div class="content">';
- echo '<div class="title">';
- echo $row['category'];
- echo '</div>';
- echo '<div class="image"><button onclick="toggle5(showDiv'.$category_id.')" ><strong>Expand</strong></button>';
- echo '</div>';
- echo '<div id="showDiv'.$category_id.'" style="display:block">';
- $cat_title = mysql_query("SELECT * FROM category_title_tbl WHERE category_id = '$category_id'") or die (mysql_error());
- while ($cat_tit=mysql_fetch_array($cat_title))
- {?>
- <input type="checkbox" value="$cat_tit['category_title']" id="cat_title" />
- <?php echo $cat_tit['category_title'];
- echo '<br />';
- }
- echo '</div>';
- echo '</div>';
- echo '</div>';
- $category_id = $category_id + 1;
- }
pls tell me how can i do this...
plsss rply..