I have a Zend Framework application based on the quick-start setup.
I\'ve gotten the demos working and am now at the point of instantiating a new model class to do some
I've define a short hand in some place I require_once() in the beginning of boostrap:
function reg($name, $value=null) {
(null===$value) || Zend_Registry::set($name, $value);
return Zend_Registry::get($name);
}
and in the bootstrap I have a:
protected function _initFinal()
{
reg('::app', $this->getApplication());
}
then I can get the Application instance anywhere by use:
$app = reg('::app');