CAdminMessage
object CAdminMessage( array $arMessage[, mixed $exception = false] )
The CAdminMessage class constructor.
Parameters
Parameter | Description |
---|---|
arMessage | An array with the following keys:
|
exception | The CApplicationException class instance which provides the error description in case it is not specified in arMessage. |
Example:
if($strError) { $aMsg = array(); $arrErr = explode("<br />",$strError); reset($arrErr); while (list(,$err)=each($arrErr)) $aMsg[]['text']=$err; $e = new CAdminException($aMsg); $GLOBALS["APPLICATION"]->ThrowException($e); $message = new CAdminMessage(GetMessage("FORM_ERROR_SAVE"), $e); echo $message->Show(); }
© «Bitrix24», 2001-2024