PHP Classes
elePHPant
Icontem

File: lib/sys_msg.php

Recommend this page to a friend!
  Classes of Muhammad Umer Farooq  >  PHP SysMsg Class  >  lib/sys_msg.php  >  Download  
File: lib/sys_msg.php
Role: Example script
Content type: text/plain
Description: Example script
Class: PHP SysMsg Class
Output application event messages
Author: By
Last change: Apply fixes from StyleCI
Date: 1 year ago
Size: 486 bytes
 

 

Contents

Class file image Download
<?php

/**
 * Create instence of class.
 *
 * @return object
 */
function sysobj()
{
    return new
SysMsg();
}
/**
 * Add system message.
 *
 * @param $msg and $type
 *
 * @return string
 */
function system_message($msg, $type = null)
{
    if (!isset(
$type) && empty($type)) {
       
$type = 'light';
    }

    return
sysobj()->add(['msg'=>$msg, 'type'=>$type]);
}
/**
 * View system message.
 *
 * @return string
 */
function view_system_message()
{
    return
sysobj()->View();
}