PHP code example of enebe-nb / phergie-irc-plugin-react-tell

1. Go to this page and download the library: Download enebe-nb/phergie-irc-plugin-react-tell 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/ */

    

enebe-nb / phergie-irc-plugin-react-tell example snippets


return array(
    'plugins' => array(
        new \EnebeNb\Phergie\Plugin\Tell\Plugin(array(
            // Send a \PDO object to use that database,
            // or leave unsetted to store the messages into an array.
            'database' => new \PDO($mydsn, $myusername, $mypassword),

            // change the default command text from 'tell' to anything
            'custom-commands' => 'mycustomcommand',
            // or pick any number of commands
            'custom-commands' => array('tell', 'ask', 'remind'),
            // also works with comma-delimited strings
            'custom-commands' => 'tell,ask,remind',

            // create database table
            'create-database' => true,

            // set a maximum number of messages to be stored for an user
            // Default: 10
            'max-messages' => 20,
            // or remove the maximum
            'max-messages' => false,
        )),

        // phergie/phergie-irc-plugin-react-command
        // is 

curl -s https://getcomposer.org/installer | php
php composer.phar install
./vendor/bin/phpunit