mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-07 02:31:40 +09:00
#19255261 외부페이지에서 <load> template 문법지원
git-svn-id: http://xe-core.googlecode.com/svn/sandbox@8152 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
a063ea81d9
commit
401bc2c5b2
2 changed files with 5 additions and 3 deletions
|
|
@ -464,7 +464,7 @@
|
|||
if(!preg_match('/^(http|https)/i',$target))
|
||||
{
|
||||
if(substr($target,0,2)=='./') $target = substr($target,2);
|
||||
if(!substr($target,0,1)!='/') $target = $web_path.$target;
|
||||
if(substr($target,0,1)!='/') $target = $web_path.$target;
|
||||
}
|
||||
|
||||
if(!$attrs['index']) $attrs['index'] = 'null';
|
||||
|
|
|
|||
|
|
@ -115,7 +115,7 @@
|
|||
// 상대경로를 절대경로로 변경
|
||||
$path_info = pathinfo($path);
|
||||
$this->path = str_replace('\\', '/', realpath($path_info['dirname'])).'/';
|
||||
$content = preg_replace_callback('/(src=|href=|url\()("|\')?([^"\'\)]+)("|\'\))?/is',array($this,'_replacePath'),$content);
|
||||
$content = preg_replace_callback('/(target=|src=|href=|url\()("|\')?([^"\'\)]+)("|\'\))?/is',array($this,'_replacePath'),$content);
|
||||
$content = preg_replace_callback('/(<!--%import\()(\")([^"]+)(\")/is',array($this,'_replacePath'),$content);
|
||||
|
||||
FileHandler::writeFile($cache_file, $content);
|
||||
|
|
@ -157,7 +157,9 @@
|
|||
|
||||
if(substr($val,0,2)=='./') $val = substr($val,2);
|
||||
$p = Context::pathToUrl($this->path);
|
||||
return sprintf("%s%s%s%s",$matches[1],$matches[2],$p.$val,$matches[4]);
|
||||
$path = sprintf("%s%s%s%s",$matches[1],$matches[2],$p.$val,$matches[4]);
|
||||
|
||||
return $path;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue