Permalink
Browse files

Merge pull request #88 from Yuanuo/patch-02

PHP basename 中文乱码问题
  • Loading branch information...
HFO4 committed Sep 15, 2018
2 parents 9ee144d + 2807c1c commit 1693bf800b5e20ad409a8893b45a1f7be2a3c9d2
Showing with 1 addition and 1 deletion.
  1. +1 −1 application/index/model/Directory.php
@@ -168,7 +168,7 @@ public function findDir($path){
$dirName = end($explode);
$rootPath = rtrim($path,"/".$dirName);
$rootPath = empty($rootPath) ? "/" : $rootPath;
$dirData = Db::name('folders')->where('owner',$this->uid)->where('position',dirname($path) == "\\" ?"/":dirname($path))->where("folder_name",basename($path))->find();
$dirData = Db::name('folders')->where('owner',$this->uid)->where('position',dirname($path) == "\\" ?"/":dirname($path))->where("folder_name",getDirName($path))->find();
if(empty($dirData)){
return false;
}

0 comments on commit 1693bf8

Please sign in to comment.