Class AdmException
- Exception implements Throwable
- AdmException
License: GNU General Public License v2.0 only **********************************************************************************************
Brief:
Admidio specific enhancements of the exception class
This class extends the default PHP exception class with an Admidio specific output. The exception get's a language string as parameter and returns a html or plain text message with the translated error if an exception is thrown
Class: AdmException
Code:
try { if($bla == 1) { throw new AdmException(LST_NOT_VALID_DATE_FORMAT); } ..
} catch(AdmException $e) { // show html message $e->showHtml();
// show simply text message $e->showText(); } @endcode
Par: Example
Located at admexception.php
Methods summary
public
|
#
__construct( string $message, string $param1 = '', string $param2 = '', string $param3 = '', string $param4 = '' )
Constructor that will @b rollback an open database translation |
public
string
|
|
public
|
#
setNewMessage( string $message, string $param1 = '', string $param2 = '', string $param3 = '', string $param4 = '' )
Set a new Admidio message id with their parameters. This method should be used if during the exception processing a new better message should be set. |
public
|
|
public
|
Methods inherited from Exception
__toString()
,
__wakeup()
,
getCode()
,
getFile()
,
getLine()
,
getMessage()
,
getPrevious()
,
getTrace()
,
getTraceAsString()
Properties inherited from Exception
$code
,
$file
,
$line
,
$message