I'm trying to build a webshop from scratch so I can learn a bit of web development.
I have created a layout that is static that I want to make dynamic with php. Im starting with the menu system. I have different categories that make the top menu level in my mega menu, then I have the subcategories that make the first level in the menu, then I have the products, now to my question.
Question: Is there a general practice for a way that I design the database to make it easy to build the menu? Right now I have a table that is named "products" that have 4 columns:
id name description category(number)
Should I add the subcategory to the same table? Which other tables should I have if I dont put all the info in one table? Hope my question make sense...
You can view my menu system here: http://www.reclam.se