/** * Notifies the necessary handlers about the alert. */ function alert() { $oSubscription = new BxDolSubscription(); $oSubscription->send($this->sUnit, $this->sAction, $this->iObject, $this->aExtras); if (isset($this->_aAlerts[$this->sUnit]) && isset($this->_aAlerts[$this->sUnit][$this->sAction])) { foreach ($this->_aAlerts[$this->sUnit][$this->sAction] as $iHandlerId) { $aHandler = $this->_aHandlers[$iHandlerId]; if (!empty($aHandler['file']) && !empty($aHandler['class']) && file_exists(BX_DIRECTORY_PATH_ROOT . $aHandler['file'])) { if (!class_exists($aHandler['class'])) { require_once BX_DIRECTORY_PATH_ROOT . $aHandler['file']; } $oHandler = new $aHandler['class'](); $oHandler->response($this); } else { if (!empty($aHandler['eval'])) { eval($aHandler['eval']); } } } } }