1. Go to this page and download the library: Download noveth/notify library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
// Target email address
$to = '[email protected]';
// Subject line
$subject = 'An example email';
// Template file name
// You can tell Notify if its a html email or not depending on the file extension
// .html files will automatically be sent as a html email
$template = 'user/registration.html';
// If you use tags in your template this is where you pass what to replace them with
$replace = [
'test tag' => 'test content'
];
// Replace {YOUR_ENDPOINT} with the webhook URL provided by slack.
Config::$SLACKWEBHOOK = '{YOUR_ENDPOINT}';
// Replace {NAME_OF_USER} with the user you want the message to be sent as (this can be anything).
Config::$SLACKUSERNAME = '{NAME_OF_USER}';