문서의 썸네일을 추출할 경우 첨부파일의 이미지를 잘못 가져와서 썸네일 생성이 안되던 문제 해결

git-svn-id: http://xe-core.googlecode.com/svn/trunk@1958 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
zero 2007-07-19 10:32:11 +00:00
parent 2474fcb6a6
commit 6e9b2f30b3

View file

@ -202,11 +202,11 @@
$tmp_file = sprintf('%sthumbnail_%d.tmp.gif', $document_path, $width);
preg_match('!src=("|\'){0,1}([^"|^\'|^\ ]*)("|\'| ){0,1}!is', $matches[0], $src_matches);
$src = $src_matches[2];
$src = str_replace(getUrl(),'',$src_matches[2]);
// 첨부된 파일일 경우
if(substr($src,0,7)=='./files') {
copy($src, $tmp_file);
if(eregi("^files", $src)) {
copy("./".$src, $tmp_file);
// 웹에서 링크한 경우
} else {