Using PHP Class
I found the class are convenient to use in the following way :
1) It simplified building the Model Logical Component of our CMS application (which is designed to have the MVC architecture) by using classes.
2) One of our class files includes 3 classes corresponding to the 3 database tables, and the other handles the task of connecting to the database.
3) The Controller Logical Component of our CMS application (which are files in movies/people/roles folders) can talk to the database by including those file classes.
It’s also very interesting to relate the class in PHP with .class in CSS. So
1) A class in PHP file is defined by using the “class” keyword followed by the name of the class).
2) A class in CSS file is defined by using the . keyword (followed by the name of the class).