| 
| static  | exception ($message, $details=[], $close_details=false) | 
|   | 
| static  | error ($message, $details=[], $close_details=false) | 
|   | 
| static  | success ($message, $details=[], $close_details=false) | 
|   | 
| static  | info ($message, $details=[], $close_details=false) | 
|   | 
| static  | warning ($message, $details=[], $close_details=false) | 
|   | 
class MessageBox
usage:
echo MessageBox::error('Nachricht', ['optional details']);
use the optional parameter $close_details for displaying the message box with closed details
echo MessageBox::success('Nachricht', ['optional details'], true); 
 
◆ __construct()
  
  
      
        
          | __construct  | 
          ( | 
            | 
          $class,  | 
         
        
           | 
           | 
            | 
          $message,  | 
         
        
           | 
           | 
            | 
          $details = [],  | 
         
        
           | 
           | 
            | 
          $close_details = false  | 
         
        
           | 
          ) | 
           |  | 
         
       
   | 
  
protected   | 
  
 
Initializes a new MessageBox object of the given class.
- Parameters
 - 
  
    | string | $class | the type of this message  | 
    | string | $message |  | 
    | array | $details | (optional)  | 
    | boolean | $close_details | (optional)  | 
  
   
 
 
◆ __toString()
This method renders a MessageBox object to a string.
- Returns
 - string html output of the message box 
 
 
 
◆ error()
  
  
      
        
          | static error  | 
          ( | 
            | 
          $message,  | 
         
        
           | 
           | 
            | 
          $details = [],  | 
         
        
           | 
           | 
            | 
          $close_details = false  | 
         
        
           | 
          ) | 
           |  | 
         
       
   | 
  
static   | 
  
 
This function returns an error message box. Use it for validation errors, problems and other wrong user input.
- Parameters
 - 
  
    | string | $message |  | 
    | array | $details | (optional)  | 
    | boolean | $close_details | (optional)  | 
  
   
- Returns
 - object MessageBox object 
 
 
 
◆ exception()
  
  
      
        
          | static exception  | 
          ( | 
            | 
          $message,  | 
         
        
           | 
           | 
            | 
          $details = [],  | 
         
        
           | 
           | 
            | 
          $close_details = false  | 
         
        
           | 
          ) | 
           |  | 
         
       
   | 
  
static   | 
  
 
This function returns an exception message box. Use it only for system errors or security related problems.
- Parameters
 - 
  
    | string | $message |  | 
    | array | $details |  | 
    | boolean | $close_details |  | 
  
   
- Returns
 - object MessageBox object 
 
 
 
◆ hideClose()
      
        
          | hideClose  | 
          ( | 
            | 
          $state = true | ) | 
           | 
        
      
 
Sets the state whether the close button should be hidden or not.
- Parameters
 - 
  
    | boolean | $state | Whether the close button should be hidden or not  | 
  
   
- Returns
 - MessageBox instance to allow chaining 
 
 
 
◆ info()
  
  
      
        
          | static info  | 
          ( | 
            | 
          $message,  | 
         
        
           | 
           | 
            | 
          $details = [],  | 
         
        
           | 
           | 
            | 
          $close_details = false  | 
         
        
           | 
          ) | 
           |  | 
         
       
   | 
  
static   | 
  
 
This function returns an info message box. Use it to report neutral informations.
- Parameters
 - 
  
    | string | $message |  | 
    | array | $details | (optional)  | 
    | boolean | $close_details | (optional)  | 
  
   
- Returns
 - object MessageBox object 
 
 
 
◆ success()
  
  
      
        
          | static success  | 
          ( | 
            | 
          $message,  | 
         
        
           | 
           | 
            | 
          $details = [],  | 
         
        
           | 
           | 
            | 
          $close_details = false  | 
         
        
           | 
          ) | 
           |  | 
         
       
   | 
  
static   | 
  
 
This function returns a success message box. Use it for confirmation of user interaction.
- Parameters
 - 
  
    | string | $message |  | 
    | array | $details | (optional)  | 
    | boolean | $close_details | (optional)  | 
  
   
- Returns
 - object MessageBox object 
 
 
 
◆ warning()
  
  
      
        
          | static warning  | 
          ( | 
            | 
          $message,  | 
         
        
           | 
           | 
            | 
          $details = [],  | 
         
        
           | 
           | 
            | 
          $close_details = false  | 
         
        
           | 
          ) | 
           |  | 
         
       
   | 
  
static   | 
  
 
This function returns a warning message box. Use it to report potentially wrong behaviour.
- Parameters
 - 
  
    | string | $message |  | 
    | array | $details | (optional)  | 
    | boolean | $close_details | (optional)  | 
  
   
- Returns
 - object MessageBox object 
 
 
 
◆ $class
type and contents of the message box 
 
 
◆ $close_details
◆ $details
◆ $hide_close
◆ $message
The documentation for this class was generated from the following file: