Hey guys, I'm building a site for motorcycles and I used mysql + php for it...
I've split the bikes to categories like: Ducati, KTM, Husqvarna, etc.
the categories table is like this:
cat_id int(10) primary (Categotry ID)
cat_name varchar(200) (Category Name)
cat_type varchar(100) (Category Bike Type: Superbikes, Sport, Enduro, Supermoto, etc.)
Here's an example record:
cat_id
1
cat_name
Ducati
cat_type
Superbikes, Sport
Now what I want is if the user clicks at Ducati for instance he will be taken to a page where he will see all the bikes splitted to categories from the cat_type row.
Is there a way to loop in the cat_type row and find out what Bike Types are in each company?
Cause Ducati will have:
cat_type -> Superbikes, Sport
Husqvarna will have: Supermoto, Enduro, etc.
Thanks in advance!