1. What is the best place for widgets in a Yii project?
Some sources say it’s best to place a widget file directly under [font=“Courier New”]protected/components[/font], while others say it’s best to place them under [font=“Courier New”]protected/extensions/widgets[/font].
2. What is the best place and naming-convention for the view scripts belonging to the widget?
Let’s say I have my widgets under [font=“Courier New”]protected/extensions/widgets[/font], like so:
protected/
extensions/
widgets/
views/
MyCalendar.php # view script for the MyCalendar widget
MyMenu.php # view script for the MyMenu widget
MyCalendar.php
MyMenu.php