Scope of PDO used in a function
May 21, 2013 in answer
ANSWER:
After bar $dbo will be “destroyed”.
Variable containers get destroyed when the “refcount” reaches zero. The “refcount” gets decreased by one when any symbol linked to the variable container leaves the scope (e.g. when the function ends) or when unset() is called on a symbol.

New Comments