show alert messages using easily using Semej
Install package using composer:
composer require academy01/semej
then add autoload
require 'vendor/autoload.php';
OR, just include Semej.php
file in to your document and Enjoy!
include_once "dist/Semej.php";
Set arguments (Status
, Title
, Body
)
Semej::set('false', 'Error 404', 'File Not Found!');
print status
Semej::status();
print title
Semej::title();
print Body
Semej::message();
delete session
Semej::unset();
this method require to bootstrap CDN
included!
with this method you can show the full alert message in your document.
in the method, valid status
value is on of These:
info
primary
danger
dark
warning
success
secondary
light
// set message like this
Semej::set('danger', 'error', 'file not found!');
// and show message like this
Semej::show();
this method require to sweetalert js cdn
included!
with thie method you can alert the body of message in your document.
Semej::alert();