November 2002
Intermediate to advanced
640 pages
16h 33m
English
You need to call a method on an object returned by another method.
Assign the object to a temporary variable, and then call the method of that temporary variable:
$orange = $fruit->get('citrus');
$orange->peel( );This is necessary because a parse error results from:
$fruit->get('citrus')->peel( );Zend Engine 2 supports direct dereferencing of objects returned from a method so this workaround is no longer necessary.
Read now
Unlock full access