/** * 构造函数,处理配置 */ public function __construct() { $params = spExt('spUrlRewrite'); if (is_array($params)) { $this->params = array_merge($this->params, $params); } }
public function __construct() { $params = spExt('spVerifyCode'); if (!empty($params['width'])) { $this->width = $params['width']; } if (!empty($params['height'])) { $this->height = $params['height']; } if (!empty($params['length'])) { $this->len = $params['length']; } if (!empty($params['bgcolor'])) { $this->backcolor = $params['bgcolor']; } if (!empty($params['noisenum'])) { $this->noisenum = $params['noisenum']; } if (!empty($params['fontsize'])) { $this->textsize = $params['fontsize']; } if (!empty($params['fontfile'])) { $this->font = str_replace('\\', '/', dirname(__FILE__)) . '/' . $params['fontfile']; } if (!empty($params['format'])) { $this->format = strtolower($params['format']); } }
public function __construct($p = null) { $params = spExt('sessionAndCookie'); if (!$p) { array_merge($params, $p); } $this->init($params); }
public function __construct() { if (!function_exists('memcache_connect')) { FeiError('PHP环境未安装Memcache函数库!'); } $params = spExt('FeiAccessCache'); $memcache_host = isset($params['memcache_host']) ? $params['memcache_host'] : 'localhost'; $memcache_port = isset($params['memcache_port']) ? $params['memcache_port'] : '11211'; $this->mmc = memcache_connect($memcache_host, $memcache_port); }
/** * 构造函数,设置权限检查程序与提示程序 */ public function __construct() { $params = spExt("spAcl"); if (!empty($params["prompt"])) { $this->prompt = $params["prompt"]; } if (!empty($params["checker"])) { $this->checker = $params["checker"]; } }
function __construct($relay_host = "", $smtp_port = 25, $auth = false, $from = '', $user = '', $pass = '') { $params = spExt("spEmail"); $this->relay_host = empty($relay_host) ? $params['smtp_host'] : $relay_host; $this->smtp_port = empty($smtp_port) ? $params['smtp_port'] : $smtp_port; $this->auth = empty($auth) ? $params['auth'] : $auth; $this->user = empty($user) ? $params['user'] : $user; $this->pass = empty($pass) ? $params['pass'] : $pass; $this->from = empty($from) ? $params['from'] : $from; if (!empty($params['debug'])) { $this->debug = $params['debug']; } if (!empty($params["time_out"])) { $this->time_out = $params["time_out"]; } if (!empty($params["log_file"])) { $this->log_file = $params["log_file"]; } if (!empty($params["host_name"])) { $this->host_name = $params["host_name"]; } $this->sock = FALSE; }