mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-04-23 04:12:18 +09:00
위젯 검출 정규 표현식을 수정
git-svn-id: http://xe-core.googlecode.com/svn/sandbox@2892 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
f9896fe51a
commit
90aa62a6ac
993 changed files with 9190 additions and 10457 deletions
|
|
@ -73,9 +73,43 @@
|
|||
$node = $output->data;
|
||||
if($node->group_srls) $node->group_srls = explode(',',$node->group_srls);
|
||||
else $node->group_srls = array();
|
||||
|
||||
$node->name = $this->getMenuItemNames($node->name);
|
||||
|
||||
return $node;
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 다국어 지원을 위해 menu의 name을 언어별로 나눠서 return
|
||||
*/
|
||||
function getMenuItemNames($name) {
|
||||
$lang_supported = Context::get('lang_supported');
|
||||
|
||||
$source_name = $name;
|
||||
$name = unserialize($name);
|
||||
|
||||
// unserialize한 값이 없으면, 즉 beta 0.2.3 이전 버전이라면 정해진 값을 모든 언어에 맞게 처리
|
||||
if(!$name) {
|
||||
$name = array();
|
||||
foreach($lang_supported as $key => $val) {
|
||||
$name[$key] = $source_name;
|
||||
}
|
||||
// 값이 있다면 혹시나 빠진 부분의 언어가 있는지 체크
|
||||
} else {
|
||||
$values = array_values($name);
|
||||
$title_name = '';
|
||||
for($i=0;$i<count($values);$i++) {
|
||||
$title_name = trim($values[$i]);
|
||||
if($title_name) break;;
|
||||
}
|
||||
foreach($lang_supported as $key => $val) {
|
||||
if(!$name[$key]) $name[$key] = $title_name;
|
||||
}
|
||||
}
|
||||
|
||||
return $name;
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief 특정 menu_srl의 정보를 이용하여 템플릿을 구한후 return
|
||||
* 관리자 페이지에서 특정 메뉴의 정보를 추가하기 위해 서버에서 tpl을 컴파일 한후 컴파일 된 html을 직접 return
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue