help with dynamic category

Discussion in 'PHP' started by parkerproject, Mar 6, 2009.

  1. #1
    am working on a project where there are categories with subcategories.all i want to do is make this categories and subcategories dynamic by pulling from database the category ,subcategory and corresponding products.
    here is my table struture

    category table
    categoryID
    categoryNAME

    sub_category table

    sub_categoryID
    category_ID
    subcategory_NAME

    product table
    product_id
    subcategory_ID
    product_name
    product_image



    my html struture looks like this

    <h4>Mens Clothing & Accessories</h4>
                       
                        	<ul>
                            	<li><a href="#">Designer</a></li>
                            	<li><a href="#">Shoes</a></li>
                            	<li><a href="#">Kitchen</a></li>
                            	<li><a href="#">Modern</a></li>
                            	<li><a href="#">Toys</a></li>
                            	<li><a href="#">Gadgets</a></li>
                            	<li><a href="#">Home Decor</a></li>
                            	<li><a href="#">Jewelry</a></li>
                            	<li><a href="#">Accessories</a></li>
                            	<li><a href="#">Eco-Friendly</a></li>
                           </ul>
                    	</div>
    HTML:

    hope i have explained this well.;)
     
    parkerproject, Mar 6, 2009 IP
  2. exodus

    exodus Well-Known Member

    Messages:
    1,900
    Likes Received:
    35
    Best Answers:
    0
    Trophy Points:
    165
    #2
    Looks great, well done! Keep up the good work. I have no idea what you need help with though.
     
    exodus, Mar 6, 2009 IP
  3. dean5000v

    dean5000v Peon

    Messages:
    201
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    maybe needs help on how to link them all in a database ?
     
    dean5000v, Mar 7, 2009 IP
  4. parkerproject

    parkerproject Active Member

    Messages:
    114
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    98
    #4
    i need help with how to generate dynamic category and subcategory
     
    parkerproject, Mar 7, 2009 IP
  5. exodus

    exodus Well-Known Member

    Messages:
    1,900
    Likes Received:
    35
    Best Answers:
    0
    Trophy Points:
    165
    #5
    Post some of your php code that you tried to do it with? We can direct you from there.
     
    exodus, Mar 7, 2009 IP