1. Go to this page and download the library: Download giginc/cakephp-rabbitmq 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/ */
giginc / cakephp-rabbitmq example snippets
Plugin::load('RabbitMQ');
use RabbitMQ\CakephpRabbitMQ as MQ;
MQ::send('email', 'this is a message');
use RabbitMQ\CakephpRabbitMQ as MQ;
// this will listen to all queues defined in the configuration file
MQ::listen();
// this will listen only to passed queues
MQ::listen(['email']);