I want to send emails with a mailgun API.
The autoload.php import succeeded with this extension
But in a row
There is an error
Thanks in advance
Code:
# Include the Autoloader (see "Libraries" for install instructions)
require 'vendor/autoload.php';
use Mailgun\Mailgun;
# First, instantiate the SDK with your API credentials
$mg = Mailgun::create('YOUR_API_KEY');
# Now, compose and send your message.
# $mg->messages()->send($domain, $params);
$mg->messages()->send('YOUR_DOMAIN_NAME', [
'from' => 'Excited User <mailgun@YOUR_DOMAIN_NAME>',
'to' => 'Baz <YOU@YOUR_DOMAIN_NAME>',
'subject' => 'Hello',
'text' => 'Testing some Mailgun awesomness!'
]);
But in a row
Code:
use Mailgun\Mailgun;
Code:
An exception occurred: [Error] Class 'shareinmambers\Mailgun' not found in src/addons/shareinmambers/sendemail.php on line 42
Thanks in advance