SmartFAQ is developed by The SmartFactory (, a division of InBox Solutions (

What are classes?
Requested by Carnuke and Answered by Mithrandir on 2004/10/28 20:55:11 (5306 reads)
Classes are structured elements used in Object Oriented programming for defining objects and grouping functions together in functional units.

An example is the XoopsUser class that defines user objects in XOOPS. The XoopsUser class defines the elements (or "properties") that describe a user; that is, a user has a username, a password, an email address and so on and some functions (or "methods") that describe actions related to a user - such as the incrementPosts() method that adds one to the user's postcount.

More information about classes and objects in PHP can be found on the website:
Classes and Objects (PHP5)
Classes and Objects (PHP4)

The comments are owned by the author. We aren't responsible for their content.