Thursday, April 5, 2018

The :: is for static properties and methods, e.g.
 MyClass::create();
The -> is for when you have an object instantiated from the class, e.g.
$myObject = new MyClass;
$myObject->create();

Leave a Reply

Subscribe to Posts | Subscribe to Comments

- Copyright © Bongvireak - Blogger Templates - Powered by Blogger - Designed by Johanes Djogan -