ÔÆÌ⺣ - רҵÎÄÕ·¶ÀýÎĵµ×ÊÁÏ·ÖÏíÆ½Ì¨

µ±Ç°Î»ÖãºÊ×Ò³ > ecshopÊÊÓ¦ÔÚPHP7µÄÐ޸ķ½·¨½â¾ö±¨´íµÄʵÏÖ

ecshopÊÊÓ¦ÔÚPHP7µÄÐ޸ķ½·¨½â¾ö±¨´íµÄʵÏÖ

  • 62 ´ÎÔĶÁ
  • 3 ´ÎÏÂÔØ
  • 2025/12/9 22:39:06

ecshopÊÊÓ¦ÔÚPHP7µÄÐ޸ķ½·¨½â¾ö±¨´íµÄʵÏÖ

ÏÂÃæÐ¡±à¾ÍΪ´ó¼Ò´øÀ´Ò»ÆªecshopÊÊÓ¦ÔÚPHP7µÄÐ޸ķ½·¨½â¾ö±¨´íµÄʵÏÖ¡£Ð¡±à¾õµÃͦ²»´íµÄ£¬ÏÖÔھͷÖÏí¸ø´ó¼Ò£¬Ò²¸ø´ó¼Ò×ö¸ö²Î¿¼¡£Ò»Æð¸úËæÐ¡±à¹ýÀ´¿´¿´°É

ecshopÕâ¸öϵͳ£¬µ½Ä¿Ç°Ò²Ã»¼ûÔõÃ´ÍÆ³öа汾£¬Èç¹ûÊÇÐÂÏîÄ¿£¬²»Ì«½¨ÒéʹÓÃËü¡£²»¹ý£¬ÒòΪÎÒÒ»Ö±ÒÔÀ´¶¼ÔÚʹÓÃÖУ¬ËùÒÔ²»µÃ²»¸ü¸ÄÈÃÆäÊÊÓ¦PHPа汾¡£ÏÖÔÚPHP 7ÒѾ­³ö·¢ÐаæÁË£¬ËùÒÔ¸ü¸ÄÀ´¼ÌÐøÊ¹Óðɡ£¾ßÌåµÄ¸ü¸ÄÓÐÒÔÏ·½Ã棺

£¨1£©½«mysqlÀ©Õ¹µÄʹÓÃÌæ»»µô£¬¸ÄΪʹÓÃmysqli»òpdo£º

´Óphp5.5¿ªÊ¼£¬mysqlÀ©Õ¹½«·ÏÆúÁË¡£

¾ßÌå¸ü¸ÄµÄÎļþÔÚÓÚincludes/cls_mysql.php¡£ÕâÊǸö²»Ð¡µÄ¹¤³Ì£¬Îļþ´úÂëÌ«³¤¡­¡­

if (!defined('DITAN_ECS')) {

die('Hacking attempt'); }

class cls_mysql {

var $link_id = NULL;

var $settings = array();

var $queryCount = 0; var $queryTime = ''; var $queryLog = array();

var $max_cache_time = 300; // ×î´óµÄ»º´æÊ±¼ä£¬ÒÔÃëΪµ¥Î»

var $cache_data_dir = 'temp/query_caches/'; var $root_path = '';

var $error_message = array(); var $platform = ''; var $version = ''; var $dbhash = ''; var $starttime = 0; var $timeline = 0; var $timezone = 0; // ÊÂÎñÖ¸ÁîÊý

protected $transTimes = 0;

var $mysql_config_cache_file_time = 0;

var $mysql_disable_cache_tables = array(); // ²»ÔÊÐí±»»º´æµÄ±í£¬Óöµ½½«²»»á½øÐлº´æ

function __construct($dbhost, $dbuser, $dbpw, $dbname = '', $charset = 'gbk', $pconnect = 0, $quiet = 0) {

$this->cls_mysql($dbhost, $dbuser, $dbpw, $dbname, $charset, $pconnect, $quiet); }

function cls_mysql($dbhost, $dbuser, $dbpw, $dbname = '', $charset = 'gbk', $pconnect = 0, $quiet = 0) {

if (defined('EC_CHARSET')) {

$charset = strtolower(str_replace('-', '', EC_CHARSET)); }

if (defined('ROOT_PATH') && !$this->root_path) {

$this->root_path = ROOT_PATH; }

if ($quiet) {

$this->connect($dbhost, $dbuser, $dbpw, $dbname, $charset, $pconnect, $quiet); } else {

$this->settings = array(

'dbhost' => $dbhost, 'dbuser' => $dbuser, 'dbpw' => $dbpw, 'dbname' => $dbname, 'charset' => $charset, 'pconnect' => $pconnect ); } }

function connect($dbhost, $dbuser, $dbpw, $dbname = '', $charset = 'utf8', $pconnect = 0, $quiet = 0) {

if ($pconnect) {

$this->link_id = new mysqli('p:'.$dbhost, $dbuser, $dbpw); if ($this->link_id->connect_error)

{

if (!$quiet) {

$this->ErrorMsg(\ }

return false; } } else {

$this->link_id = new mysqli($dbhost, $dbuser, $dbpw);

if ($this->link_id->connect_error) {

if (!$quiet) {

$this->ErrorMsg(\ }

return false; } }

$this->dbhash = md5($this->root_path . $dbhost . $dbuser . $dbpw . $dbname); $this->version = $this->link_id->server_version;

/* ¶Ô×Ö·û¼¯½øÐгõʼ»¯ */ $this->link_id->set_charset($charset);

$this->link_id->query(\

$sqlcache_config_file = $this->root_path . $this->cache_data_dir . 'sqlcache_config_file_' . $this->dbhash . '.php';

@include($sqlcache_config_file);

$this->starttime = time();

if ($this->max_cache_time && $this->starttime > $this->mysql_config_cache_file_time + $this->max_cache_time) {

if ($dbhost != '.') {

$result = $this->link_id->query(\ $row = $result->fetch_array(MYSQLI_ASSOC); $result->free();

if (!empty($row['Value']{1}) && $row['Value']{1} == ':' && !empty($row['Value']{2}) && $row['Value']{2} == \ {

$this->platform = 'WINDOWS'; } else {

$this->platform = 'OTHER'; } } else {

$this->platform = 'WINDOWS'; }

if ($this->platform == 'OTHER' &&

($dbhost != '.' && strtolower($dbhost) != 'localhost:3306' && $dbhost != '127.0.0.1:3306') || date_default_timezone_get() == 'UTC') {

$result = $this->link_id->query(\UNIX_TIMESTAMP() AS timeline, UNIX_TIMESTAMP('\. date('Y-m-d H:i:s', $this->starttime) . \

$row = $result->fetch_array(MYSQLI_ASSOC); $result->free();

if ($dbhost != '.' && strtolower($dbhost) != 'localhost:3306' && $dbhost != '127.0.0.1:3306') {

$this->timeline = $this->starttime - $row['timeline']; }

if (date_default_timezone_get() == 'UTC') {

$this->timezone = $this->starttime - $row['timezone']; } }

$content = '<' . \

'$this->mysql_config_cache_file_time = ' . $this->starttime . \ '$this->timeline = ' . $this->timeline . \ '$this->timezone = ' . $this->timezone . \ '$this->platform = ' . \

@file_put_contents($sqlcache_config_file, $content); }

/* Ñ¡ÔñÊý¾Ý¿â */ if ($dbname) {

  • ÊÕ²Ø
  • Î¥¹æ¾Ù±¨
  • °æÈ¨ÈÏÁì
ÏÂÔØÎĵµ10.00 Ôª ¼ÓÈëVIPÃâ·ÑÏÂÔØ
ÍÆ¼öÏÂÔØ
±¾ÎÄ×÷Õߣº...

¹²·ÖÏí92ƪÏà¹ØÎĵµ

Îĵµ¼ò½é£º

ecshopÊÊÓ¦ÔÚPHP7µÄÐ޸ķ½·¨½â¾ö±¨´íµÄʵÏÖ ÏÂÃæÐ¡±à¾ÍΪ´ó¼Ò´øÀ´Ò»ÆªecshopÊÊÓ¦ÔÚPHP7µÄÐ޸ķ½·¨½â¾ö±¨´íµÄʵÏÖ¡£Ð¡±à¾õµÃͦ²»´íµÄ£¬ÏÖÔھͷÖÏí¸ø´ó¼Ò£¬Ò²¸ø´ó¼Ò×ö¸ö²Î¿¼¡£Ò»Æð¸úËæÐ¡±à¹ýÀ´¿´¿´°É ecshopÕâ¸öϵͳ£¬µ½Ä¿Ç°Ò²Ã»¼ûÔõÃ´ÍÆ³öа汾£¬Èç¹ûÊÇÐÂÏîÄ¿£¬²»Ì«½¨ÒéʹÓÃËü¡£²»¹ý£¬ÒòΪÎÒÒ»Ö±ÒÔÀ´¶¼ÔÚʹÓÃÖУ¬ËùÒÔ²»µÃ²»¸ü¸ÄÈÃÆäÊÊÓ¦PHPа汾¡£ÏÖÔÚPHP 7ÒѾ­³ö·¢ÐаæÁË£¬ËùÒÔ¸ü¸ÄÀ´¼ÌÐøÊ¹Óðɡ£¾ßÌåµÄ¸ü¸ÄÓÐÒÔÏ·½Ã棺 £¨1£©½«mysqlÀ©Õ¹µÄʹÓÃÌæ»»µô£¬¸ÄΪʹÓÃmysqli»òpdo£º ´Óphp5.5¿ªÊ¼£¬mysqlÀ©Õ¹½«·ÏÆúÁË¡£ ¾ßÌå¸ü¸ÄµÄÎļþÔÚÓÚincludes/cls_mysql.php¡£ÕâÊǸö²»Ð¡µÄ¹¤³Ì£¬Îļþ´úÂëÌ«³¤¡­¡­ if (!defined('DITAN_ECS'))

¡Á ÓοͿì½ÝÏÂÔØÍ¨µÀ£¨ÏÂÔØºó¿ÉÒÔ×ÔÓɸ´ÖƺÍÅŰ棩
µ¥Æª¸¶·ÑÏÂÔØ
ÏÞÊ±ÌØ¼Û£º10 Ôª/·Ý Ô­¼Û:20Ôª
VIP°üÔÂÏÂÔØ
ÌØ¼Û£º29 Ôª/Ô ԭ¼Û:99Ôª
µÍÖÁ 0.3 Ôª/·Ý ÿÔÂÏÂÔØ150·Ý
ȫվÄÚÈÝÃâ·Ñ×ÔÓɸ´ÖÆ
VIP°üÔÂÏÂÔØ
ÌØ¼Û£º29 Ôª/Ô ԭ¼Û:99Ôª
µÍÖÁ 0.3 Ôª/·Ý ÿÔÂÏÂÔØ150·Ý
ȫվÄÚÈÝÃâ·Ñ×ÔÓɸ´ÖÆ
×¢£ºÏÂÔØÎĵµÓпÉÄÜ¡°Ö»ÓÐĿ¼»òÕßÄÚÈݲ»È«¡±µÈÇé¿ö£¬ÇëÏÂÔØÖ®Ç°×¢Òâ±æ±ð£¬Èç¹ûÄúÒѸ¶·ÑÇÒÎÞ·¨ÏÂÔØ»òÄÚÈÝÓÐÎÊÌ⣬ÇëÁªÏµÎÒÃÇЭÖúÄã´¦Àí¡£
΢ÐÅ£ºfanwen365 QQ£º370150219
Copyright © ÔÆÌ⺣ All Rights Reserved. ËÕICP±¸16052595ºÅ-3 ÍøÕ¾µØÍ¼ ¿Í·þQQ£º370150219 ÓÊÏ䣺370150219@qq.com