Browse Source

sqlite兼容处理

tags/6.2.12
tianya 1 year ago
parent
commit
4c20bdbfd9
3 changed files with 3 additions and 1 deletions
  1. +1
    -0
      dedebiz
  2. +1
    -0
      src/system/database/dedesqlite.class.php
  3. +1
    -1
      src/system/taglib/channel/img.lib.php

+ 1
- 0
dedebiz View File

@@ -480,6 +480,7 @@ if (count($argv) > 1 && ($argv[1] == "serv" || $argv[1] == "s")) {
$dsql->ExecuteNoneQuery("DELETE FROM `#@__arctiny` WHERE id='$arcID'"); $dsql->ExecuteNoneQuery("DELETE FROM `#@__arctiny` WHERE id='$arcID'");
DedeCli::error("数据保存到数据库附加表时出错,请检查数据库字段".str_replace('"', '', $gerr)); DedeCli::error("数据保存到数据库附加表时出错,请检查数据库字段".str_replace('"', '', $gerr));
} }
InsertTags("天涯{$arcID},穆云智能", $arcID);
} }
DedeCli::write("成功生成所有测试数据"); DedeCli::write("成功生成所有测试数据");
} else if(count($argv) > 1 && ($argv[1] =="pwd")){ } else if(count($argv) > 1 && ($argv[1] =="pwd")){


+ 1
- 0
src/system/database/dedesqlite.class.php View File

@@ -494,6 +494,7 @@ class DedeSqlite
$this->queryString = preg_replace("/Show Tables/i", "SELECT name FROM sqlite_master WHERE type = \"table\"", $this->queryString); $this->queryString = preg_replace("/Show Tables/i", "SELECT name FROM sqlite_master WHERE type = \"table\"", $this->queryString);
$this->queryString = str_replace("\'", "\"", $this->queryString); $this->queryString = str_replace("\'", "\"", $this->queryString);
$this->queryString = str_replace('\t\n', "", $this->queryString); $this->queryString = str_replace('\t\n', "", $this->queryString);
$this->queryString = str_ireplace('rand', 'RANDOM', $this->queryString);
//var_dump($this->queryString); //var_dump($this->queryString);
} }
function SetSql($sql) function SetSql($sql)


+ 1
- 1
src/system/taglib/channel/img.lib.php View File

@@ -16,7 +16,7 @@ function ch_img($fvalue, &$arcTag, &$refObj, $fname = '')
$dtp->LoadSource($fvalue); $dtp->LoadSource($fvalue);
if (!is_array($dtp->CTags)) { if (!is_array($dtp->CTags)) {
$dtp->Clear(); $dtp->Clear();
return "无图片信息";
return $fvalue;
} }
$pagestyle = $cfg_album_style; $pagestyle = $cfg_album_style;
$maxwidth = $cfg_album_width; $maxwidth = $cfg_album_width;


Loading…
Cancel
Save