What are components for?


I am experiencing problems considering the write implementation of "Extracting cities from database" and filling data in dropDownlist. That's why I opened the blog tutorial demo and looked about Tags and Comments. Then, I saw the components folder, full of files. What is it exactly for?

The purpose for the components folder (in the protected directory) is to store classes (based on the CComponent class) that containes logic that might be shared between several controllers or other classes, where the logic can not cleanly be defined to be a view, model or controller.

krillzip, thank you for explanation. For larger projects, you may want to create sub-directories of components to better categorize the components.

Thank you very much guys!

thanks guyssssssss

now i know, the purpose of components folder. thank u