第一范文网 - 专业文章范例文档资料分享平台

ecshop适应在PHP7的修改方法解决报错的实现

来源:用户分享 时间:2025/6/16 19:53:13 本文由loading 分享 下载这篇文档手机版
说明:文章内容仅供预览,部分内容可能不全,需要完整文档或者需要复制内容,请下载word后使用。下载word有问题请添加微信号:xxxxxxx或QQ:xxxxxx 处理(尽可能给您提供完整文档),感谢您的支持与谅解。

function close() {

return $this->link_id->close(); }

function ErrorMsg($message = '', $sql = '') {

if ($message) {

echo \ //print('

href=\target=\ } else {

echo \ print_r($this->error_message);

//echo %urlencode($this->error_message[2]['error']) . \ } exit; }

/* 仿真 Adodb 函数 */

function selectLimit($sql, $num, $start = 0) {

if ($start == 0) {

$sql .= ' LIMIT ' . $num; } else {

$sql .= ' LIMIT ' . $start . ', ' . $num; }

return $this->query($sql); }

function getOne($sql, $limited = false) {

if ($limited == true) {

$sql = trim($sql . ' LIMIT 1'); }

$res = $this->query($sql); if ($res !== false) {

$row = $res->fetch_row(); $res->free(); if ($row !== false) {

return $row[0]; } else {

return ''; } } else {

return false; } }

function getOneCached($sql, $cached = 'FILEFIRST') {

$sql = trim($sql . ' LIMIT 1');

$cachefirst = ($cached == 'FILEFIRST' || ($cached == 'MYSQLFIRST' && $this->platform != 'WINDOWS')) && $this->max_cache_time; if (!$cachefirst) {

return $this->getOne($sql, true); } else {

$result = $this->getSqlCacheData($sql, $cached); if (empty($result['storecache']) == true) {

return $result['data']; } }

$arr = $this->getOne($sql, true);

if ($arr !== false && $cachefirst)

{

$this->setSqlCacheData($result, $arr); }

return $arr; }

function getAll($sql) {

$res = $this->query($sql); if ($res !== false) {

$arr = $res->fetch_all(MYSQLI_ASSOC); $res->free(); return $arr; } else {

return false; } }

function getAllCached($sql, $cached = 'FILEFIRST') {

$cachefirst = ($cached == 'FILEFIRST' || ($cached == 'MYSQLFIRST' && $this->platform != 'WINDOWS')) && $this->max_cache_time; if (!$cachefirst) {

return $this->getAll($sql); } else {

$result = $this->getSqlCacheData

ecshop适应在PHP7的修改方法解决报错的实现.doc 将本文的Word文档下载到电脑,方便复制、编辑、收藏和打印
本文链接:https://www.diyifanwen.net/c0e4cf8drjv9vfqx3d4pq7px008twlp015f4_3.html(转载请注明文章来源)
热门推荐
Copyright © 2012-2023 第一范文网 版权所有 免责声明 | 联系我们
声明 :本网站尊重并保护知识产权,根据《信息网络传播权保护条例》,如果我们转载的作品侵犯了您的权利,请在一个月内通知我们,我们会及时删除。
客服QQ:xxxxxx 邮箱:xxxxxx@qq.com
渝ICP备2023013149号
Top