PicHome 2.0.1

This commit is contained in:
zyx0814
2024-02-06 00:03:33 +08:00
Unverified
parent e464a1bdb9
commit 5d3da83e43
113 changed files with 1473 additions and 1017 deletions

View File

@@ -528,7 +528,7 @@ class io_dzz extends io_api
$data = C::t('pichome_resources')->fetch_data_by_rid($path);
return $data;
} else {
$path = $this->parsePath($path);
// $path = $this->parsePath($path);
global $Types;
$pathinfo = pathinfo($path);
$ext = strtolower($pathinfo['extension']);
@@ -667,13 +667,7 @@ class io_dzz extends io_api
$path = str_replace('dzz::','',$path);
return getglobal('setting/attachurl') . $path;
}else{
$path = $this->parsePath($path);
$localpath = BS . $path;
if(is_file($localpath)){
return $localpath;
}else{
return $path;
}
return $path;
}
}
@@ -698,16 +692,8 @@ class io_dzz extends io_api
$resources = C::t('resources')->fetch_data_by_rid($path);
return IO::getStream($resources['path']);
}else{
$path = $this->parsePath($path);
$localpath = BS . $path;
if(is_file(getglobal('setting/attachdir') . $path)){
return getglobal('setting/attachdir') . $path;
}
elseif(is_file($localpath)){
return $localpath;
}else{
return $path;
}
return $path;
}
}