Hi everyone!
I’m very new to Yii but I think it’s a really great framework. I followed most of the tutorials and now I want to start my own application and I need your help.
The structure of my website will be:
Category1 (type=articles)
-Sub-category 1-1
–Sub-sub-category1
—Article 1
—Article 2
—Article 3
…
-Sub-category 1-2
–Sub-sub-category1
—Article 1
…
Category2 (type=news&events)
-Sub-category 1
–Sub-sub-category 1
—News1
—News2
—News3
-Sub-category 2
…
What I want to achieve:
-
On the category view to retrieve all sub-categories and recursively sub-sub-categories
-
On the sub-sub-categories to list all the articles/ news with links to a full article/ news
Should I create a different controller for each category type, or have a "type" field in the category table?
>>tbl_category
-id
-name
-type (ex: articles, news)
-description
I’d really appreciate your help!
Roadie