1- Objects is collection of member variables(member data and member function)
2- Object is an instance of a class
3- Object use some space in memory
4- Object is real word entity
5- Banana,apple,orange are example of object
6- You and me are example of of object
7- Chair,Table are example of objects
1- Class is group of objects with same attributes and common behaviors
2- Class is set of objects
3- Class don't use space in memory
4- Class is user defined datatype
5- Class is logical entity
6- Fruit is example of class
7- Person is example of class
8- Furniture is example of class
class test { function myFunc() { echo "Welcome Class..."; } } $obj = new test(); $obj->myFunc(); //Output Welcome Class... //test is class name //$obj is object name