git-svn-id: http://xe-core.googlecode.com/svn/trunk@1828 201d5d3c-b55e-5fd7-737f-ddc643e51545

This commit is contained in:
zero 2007-06-29 08:50:38 +00:00
parent 5d31f4cba5
commit 3eaea3f33a
106 changed files with 351 additions and 253 deletions

View file

@ -781,6 +781,9 @@
function transContent($content) {
// 위젯 코드 변경
$content = preg_replace_callback('!<img([^\>]*)widget=([^\>]*?)\>!is', array($this,'_transWidget'), $content);
// 메타 파일 변경
$content = preg_replace_callback('!<\!\-\-Meta:([^\-]*?)\-\->!is', array($this,'_transMeta'), $content);
// 에디터 컴포넌트를 찾아서 결과 코드로 변환
$content = preg_replace_callback('!<div([^\>]*)editor_component=([^\>]*)>(.*?)\<\/div\>!is', array($this,'_transEditorComponent'), $content);
@ -811,6 +814,14 @@
return sprintf('<%s%s%s>', $matches[1], strtolower($matches[2]), $matches[3]);
}
/**
* @brief <!--Meta:파일이름.(css|js)--> 변경
**/
function _transMeta($matches) {
if(eregi('\.css$', $matches[1])) $this->addCSSFile($matches[1]);
elseif(eregi('\.js$', $matches[1])) $this->addJSFile($matches[1]);
}
/**
* @brief <body>내의 <style태그를 header로 이동
**/
@ -871,6 +882,14 @@
if(!$vars->widget) return "";
// 캐시 체크
$widget_sequence = $vars->widget_sequence;
$widget_cache = $vars->widget_cache;
if($widget_cache && $widget_sequence) {
$output = WidgetHandler::getCache($widget_sequence, $widget_cache);
if($output) return $output;
}
// 위젯의 이름을 구함
$widget = $vars->widget;
unset($vars->widget);