if (file_exists($sFilePath)) {
$sTitle = $sFilePath;
$sTitle = strrchr($sTitle, "/");
$sTitle = ltrim($sTitle, ‘/‘);
$this->downloadFile($sTitle, $sFilePath);
}
其实就是切割 如用户上传路径可能是 /Data/wwwroot/edu/xxx/bbb 这时我们只需要bbb,切割符合的就行了
原文:http://www.cnblogs.com/zzg521/p/6443158.html