mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-27 15:19:57 +09:00
git-svn-id: http://xe-core.googlecode.com/svn/trunk@704 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
e93576f6b6
commit
c8d510cc47
3 changed files with 16 additions and 0 deletions
|
|
@ -7,6 +7,8 @@
|
||||||
|
|
||||||
class PluginHandler {
|
class PluginHandler {
|
||||||
|
|
||||||
|
var $plugin_path = '';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief 플러그인을 찾아서 실행하고 결과를 출력
|
* @brief 플러그인을 찾아서 실행하고 결과를 출력
|
||||||
* <div plugin='플러그인'...></div> 태그 사용 templateHandler에서 PluginHandler::execute()를 실행하는 코드로 대체하게 된다
|
* <div plugin='플러그인'...></div> 태그 사용 templateHandler에서 PluginHandler::execute()를 실행하는 코드로 대체하게 된다
|
||||||
|
|
@ -42,6 +44,8 @@
|
||||||
if(!is_object($oPlugin)) return sprintf(Context::getLang('msg_plugin_object_is_null'), $plugin);
|
if(!is_object($oPlugin)) return sprintf(Context::getLang('msg_plugin_object_is_null'), $plugin);
|
||||||
if(!method_exists($oPlugin, 'proc')) return sprintf(Context::getLang('msg_plugin_proc_is_null'), $plugin);
|
if(!method_exists($oPlugin, 'proc')) return sprintf(Context::getLang('msg_plugin_proc_is_null'), $plugin);
|
||||||
|
|
||||||
|
$oPlugin->plugin_path = $path;
|
||||||
|
|
||||||
return $oPlugin;
|
return $oPlugin;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -32,6 +32,17 @@
|
||||||
$output = $oDocumentModel->getDocumentList($obj);
|
$output = $oDocumentModel->getDocumentList($obj);
|
||||||
|
|
||||||
// 템플릿 파일을 지정
|
// 템플릿 파일을 지정
|
||||||
|
$tpl_path = $this->plugin_path.'skins/default';
|
||||||
|
$tpl_file = 'list';
|
||||||
|
|
||||||
|
// 템플릿 파일에서 사용할 변수들을 세팅
|
||||||
|
Context::set('title', $title);
|
||||||
|
Context::set('list', $list);
|
||||||
|
|
||||||
|
// 템플릿 컴파일
|
||||||
|
$oTemplate = new TemplateHandler();
|
||||||
|
debugPrint($tpl_path);
|
||||||
|
return $oTemplate->compile($tpl_path, $tpl_file);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
1
plugins/newest_document/skins/default/list.html
Normal file
1
plugins/newest_document/skins/default/list.html
Normal file
|
|
@ -0,0 +1 @@
|
||||||
|
{$title}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue