An object is a specific instance of a class.
Every object instance is completely independent and has properties and methods.
Objects are also known as instance.
To create a new object, use the new statement to instantiate a class:
<?php class foo { function show() { echo "This is the show method"; } } $bar = new foo; //$bar->show(); var_dump($bar); ?>
Output:
object(foo)#1 (0) { }