mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-20 00:12:15 +00:00
- application/core/* -> CS compliant
- application/libraries/* -> CS compliant - FHC_Model isEntitled method now return error() or success() - Updated all code that uses isEntitled method from FHC_Model - Removed Squiz.PHP.DisallowSizeFunctionsInLoops from CS ruleset - Removed depracated method replace from DB_Model - Removed unused method pgArrayPhp from DB_Model - Renamed method arrayMergeIndex to _arrayCombine in DB_Model and set as private - Added method _manageUDFs to DB_Model (a wrapper for UDFLib->manageUDFs)
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
if (! defined("BASEPATH")) exit("No direct script access allowed");
|
||||
if (! defined('BASEPATH')) exit('No direct script access allowed');
|
||||
|
||||
/**
|
||||
* Library to manage the sending of the email
|
||||
@@ -27,33 +27,33 @@ class MailLib
|
||||
$this->ci =& get_instance();
|
||||
|
||||
// The second parameter is used to avoiding name collisions in the config array
|
||||
$this->ci->config->load("mail", true);
|
||||
$this->ci->config->load('mail', true);
|
||||
|
||||
// CI Email library
|
||||
$this->ci->load->library("email");
|
||||
$this->ci->load->library('email');
|
||||
|
||||
// Initializing email library with the loaded configurations
|
||||
$this->ci->email->initialize($this->ci->config->config["mail"]);
|
||||
$this->ci->email->initialize($this->ci->config->config['mail']);
|
||||
|
||||
// Set the configuration properties with the standard configuration values
|
||||
$this->email_number_to_sent = $this->getEmailCfgItem("email_number_to_sent");
|
||||
$this->email_number_per_time_range = $this->getEmailCfgItem("email_number_per_time_range");
|
||||
$this->email_time_range = $this->getEmailCfgItem("email_time_range");
|
||||
$this->email_from_system = $this->getEmailCfgItem("email_from_system");
|
||||
$this->alias_from_system = $this->getEmailCfgItem("alias_from_system");
|
||||
$this->email_number_to_sent = $this->getEmailCfgItem('email_number_to_sent');
|
||||
$this->email_number_per_time_range = $this->getEmailCfgItem('email_number_per_time_range');
|
||||
$this->email_time_range = $this->getEmailCfgItem('email_time_range');
|
||||
$this->email_from_system = $this->getEmailCfgItem('email_from_system');
|
||||
$this->alias_from_system = $this->getEmailCfgItem('alias_from_system');
|
||||
}
|
||||
|
||||
/**
|
||||
* Sends a single email
|
||||
*/
|
||||
public function send($from, $to, $subject, $message, $alias = "", $cc = null, $bcc = null, $altMessage = '')
|
||||
public function send($from, $to, $subject, $message, $alias = '', $cc = null, $bcc = null, $altMessage = '')
|
||||
{
|
||||
// If from is not specified then use the standard one
|
||||
if (is_null($from) || $from == "")
|
||||
if (is_null($from) || $from == '')
|
||||
{
|
||||
$from = $this->email_from_system;
|
||||
// If alias is not specified then use the standard one
|
||||
if (is_null($alias) || $alias == "")
|
||||
if (is_null($alias) || $alias == '')
|
||||
{
|
||||
$alias = $this->alias_from_system;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user