Index: trunk/globals.php =================================================================== diff -u -N -r3330 -r3534 --- trunk/globals.php (.../globals.php) (revision 3330) +++ trunk/globals.php (.../globals.php) (revision 3534) @@ -2051,5 +2051,14 @@ return defined($const_name) && constant($const_name); } } + + function &recallObject($var_name, $class_name) + { + if (!isset($GLOBALS[$var_name]) || !is_object($GLOBALS[$var_name])) + { + $GLOBALS[$var_name] = new $class_name(); + } + return $GLOBALS[$var_name]; + } ?>