Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /**
- *
- * @ This file is created by http://DeZender.Net
- * @ deZender (PHP7 Decoder for ionCube Encoder)
- *
- * @ Version : 4.1.0.1
- * @ Author : DeZender
- * @ Release on : 29.08.2020
- * @ Official site : http://DeZender.Net
- *
- */
- namespace whmcs\module\mail;
- class PhpMail implements \WHMCS\Module\Contracts\SenderModuleInterface
- {
- use \WHMCS\Module\MailSender\DescriptionTrait;
- protected $mailer;
- public function __construct()
- {
- $this->setDisplayName('PHP Mail (Default)');
- }
- public function settings()
- {
- return [
- 'encoding' => ['FriendlyName' => \AdminLang::trans('general.mailencoding'), 'Type' => 'dropdown', 'Options' => \WHMCS\Mail\PhpMailer::getValidEncodings(), 'Default' => 0]
- ];
- }
- public function testConnection(array $params)
- {
- $mail = $this->phpMailerInstance($params);
- $fromEmail = \WHMCS\Config\Setting::getValue('SystemEmailsFromEmail');
- $fromName = \WHMCS\Config\Setting::getValue('SystemEmailsFromName');
- $currentAdmin = \WHMCS\User\Admin::find(\WHMCS\Session::get('adminid'));
- $mail->addAddress($currentAdmin->email, $currentAdmin->fullName);
- if (\WHMCS\Config\Setting::getValue('BCCMessages')) {
- $bcc = \WHMCS\Config\Setting::getValue('BCCMessages');
- $bcc = explode(',', $bcc);
- foreach ($bcc as $value) {
- if (trim($value)) {
- .............................................................................
- ...............................................
- ....................
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement