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

This commit is contained in:
zero 2007-03-08 10:07:48 +00:00
parent aa6f3b6bf6
commit c8eb86356e
18 changed files with 61 additions and 27 deletions

View file

@ -162,6 +162,12 @@
}
}
// 현재 페이지의 정보를 $zbfe_url이라는 변수로 등록 (common/tpl/common_header.tpl에서 javascript 변수로 설정함)
if($_REQUEST['mid']) $zbfe_url = sprintf('mid=%s',$_REQUEST['mid']);
elseif($_REQUEST['module']) $zbfe_url = sprintf('module=%s',$_REQUEST['module']);
else $zbfe_url = Context::getRequestUri();
Context::set('zbfe_url', $zbfe_url);
// 해당 모듈에 layout_srl이 있는지 확인
if($oModule->module_info->layout_srl) {
// layout_srl이 있으면 해당 레이아웃 정보를 가져와 layout_path/ layout_file 위치 변경
@ -191,12 +197,6 @@
$oModule->setLayoutFile('layout');
}
// 현재 페이지의 정보를 $zbfe_url이라는 변수로 등록 (common/tpl/common_header.tpl에서 javascript 변수로 설정함)
if($_REQUEST['mid']) $zbfe_url = sprintf('mid=%s',$_REQUEST['mid']);
elseif($_REQUEST['module']) $zbfe_url = sprintf('module=%s',$_REQUEST['module']);
else $zbfe_url = Context::getRequestUri();
Context::set('zbfe_url', $zbfe_url);
// 컨텐츠 출력
$oDisplayHandler = new DisplayHandler();
$oDisplayHandler->printContent($oModule);

View file

@ -81,8 +81,8 @@
// 이미지 태그 img의 src의 값이 ./ 로 시작하면 {$tpl_path}로 변경
$buff = preg_replace_callback('!src=[\'"]{1}(.*?)[\'"]{1}!is', array($this, '_compileImgPath'), $buff);
// 함수를 변경
$buff = preg_replace_callback('/\{\@([^\}]+)\}/i', array($this, '_compileVarToFunc'), $buff);
// 결과를 출력하지 않는 구문 변경
$buff = preg_replace_callback('/\{\@([^\}]+)\}/i', array($this, '_compileVarToSilenceExecute'), $buff);
// <!--@, --> 의 변경
$buff = preg_replace_callback('!<\!--@(.*?)-->!is', array($this, '_compileFuncToCode'), $buff);
@ -126,8 +126,8 @@
/**
* @brief {@ } 안의 @... 함수를 print func(..) 변경
**/
function _compileVarToFunc($matches) {
return '<?php print('.preg_replace('/\$([a-zA-Z0-9\_\-\>]+)/i','$__Context->\\1', trim($matches[1])).');?>';
function _compileVarToSilenceExecute($matches) {
return '<?php @'.preg_replace('/\$([a-zA-Z0-9\_\-\>]+)/i','$__Context->\\1', trim($matches[1])).';?>';
}
/**

View file

@ -4,6 +4,41 @@
</script>
<div style="height:50px;border:1px solid;margin-bottom:10px;">
{$layout_info->top_title}
<div style="float:right">
<div>
<!-- 1차 메뉴 -->
<!--@foreach($main_menu->list as $key => $val)-->
<!--@if($zbfe_url==$val['url'])-->
{@ $selected_style = 'style="font-weight:bold;"'}
{@ $second_menu_list = $val['list']; }
<!--@else-->
{@ $selected_style = ''; }
<!--@end-->
<span {$selected_style}>
<a href="#" onclick="location.href='{$val['href']}';return false;">{$val['text']}</a>
</span>
<!--@end-->
</div>
<div>
<!-- 2차 메뉴 -->
<!--@foreach($second_menu_list as $key => $val)-->
<!--@if($zbfe_url==$val['url'])-->
{@ $selected_style = 'style="font-weight:bold;"'}
<!--@else-->
{@ $selected_style = ''; }
<!--@end-->
<span {$selected_style}>
<a href="#" onclick="location.href='{$val['href']}';return false;">{$val['text']}</a>
</span>
<!--@end-->
</div>
</div>
</div>
<div>
<div id="menu" style="position:absolute;"></div>

View file

@ -16,7 +16,7 @@
</tr>
<tr>
<td colspan="2">
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{@getUrl('act','')}'" />
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{getUrl('act','')}'" />
<input type="submit" value="{$lang->cmd_login}" />
</td>
</tr>

View file

@ -11,7 +11,7 @@
</tr>
<tr>
<td>
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{@getUrl('act','')}'" />
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{getUrl('act','')}'" />
<input type="submit" value="{$lang->cmd_logout}" />
</td>
</tr>

View file

@ -62,7 +62,7 @@
<td colspan="2">
<!--@if($act&&$act!='dispContent')-->
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{@getUrl('act','')}'" />
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{getUrl('act','')}'" />
<!--@end-->
<input type="submit" value="{$lang->cmd_registration}" accesskey="s" />

View file

@ -13,7 +13,7 @@
<tr>
<td colspan="2">
<input type="submit" value="{$lang->cmd_delete}" />
<input type="button" value="{$lang->cmd_back}" onclick="location.href='{@getUrl('act','')}'" />
<input type="button" value="{$lang->cmd_back}" onclick="location.href='{getUrl('act','')}'" />
</td>
</tr>
</table>

View file

@ -16,7 +16,7 @@
<tr>
<td colspan="2">
<input type="submit" value="{$lang->cmd_delete}" />
<input type="button" value="{$lang->cmd_back}" onclick="location.href='{@getUrl('act','')}'" />
<input type="button" value="{$lang->cmd_back}" onclick="location.href='{getUrl('act','')}'" />
</td>
</tr>
</table>

View file

@ -13,7 +13,7 @@
<tr>
<td colspan="2">
<input type="submit" value="{$lang->cmd_delete}" />
<input type="button" value="{$lang->cmd_back}" onclick="location.href='{@getUrl('act','')}'" />
<input type="button" value="{$lang->cmd_back}" onclick="location.href='{getUrl('act','')}'" />
</td>
</tr>
</table>

View file

@ -17,7 +17,7 @@
<tr>
<td colspan="2">
<input type="submit" value="{$lang->cmd_input}" />
<input type="button" value="{$lang->cmd_back}" onclick="location.href='{@getUrl('act','','document_srl','','comment_srl','')}'" />
<input type="button" value="{$lang->cmd_back}" onclick="location.href='{getUrl('act','','document_srl','','comment_srl','')}'" />
</td>
</tr>
</table>

View file

@ -12,7 +12,7 @@
</tr>
<tr>
<td>
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{@getUrl('act','')}'" />
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{getUrl('act','')}'" />
<input type="submit" value="{$lang->cmd_logout}" />
</td>
</tr>

View file

@ -98,7 +98,7 @@
</tr>
<tr>
<td colspan="2">
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{@getUrl('act','')}'" />
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{getUrl('act','')}'" />
<input type="submit" value="{$lang->cmd_registration}" accesskey="s" />
</td>
</tr>

View file

@ -12,7 +12,7 @@
</tr>
<tr>
<td colspan="2">
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{@getUrl('act','')}'" />
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{getUrl('act','')}'" />
<input type="submit" value="{$lang->cmd_registration}" accesskey="s" />
</td>
</tr>

View file

@ -25,7 +25,7 @@
</tr>
<tr>
<td colspan="2">
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{@getUrl('act','')}'" />
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{getUrl('act','')}'" />
<input type="submit" value="{$lang->cmd_registration}" accesskey="s" />
</td>
</tr>

View file

@ -249,7 +249,6 @@
$php_buff = sprintf('<?php if(!__ZB5__) exit(); $menu->list = array(%s); ?>', $this->getPhpCacheCode($tree[0], $tree));
FileHandler::writeFile($xml_file, $xml_buff);
FileHandler::writeFile($php_file, $php_buff);
return $xml_file;
}
@ -300,7 +299,7 @@
else $node->href = $node->url;
$attribute = sprintf(
'"node_srl"=>"%s","text"=>"%s","href"=>"%s","url"=>"%s","open_window"=>"%s","normal_btn"=>"%s","hover_btn"=>"%s","active_btn"=>"%s","group_srls"=>array(%s),%s',
'"node_srl"=>"%s","text"=>"%s","href"=>"%s","url"=>"%s","open_window"=>"%s","normal_btn"=>"%s","hover_btn"=>"%s","active_btn"=>"%s","group_srls"=>array(%s),"list"=>array(%s)',
$node->menu_srl,
str_replace(array('&','"','<','>'),array('&amp;','&quot;','&lt;','&gt;'),$node->name),
str_replace(array('&','"','<','>'),array('&amp;','&quot;','&lt;','&gt;'),$node->href),
@ -313,7 +312,7 @@
$child_buff
);
$buff .= sprintf('%s=>array(%s),'."\n", $node->menu_srl, $attribute);
$buff .= sprintf('%s=>array(%s),', $node->menu_srl, $attribute);
}
return $buff;
}

View file

@ -26,7 +26,7 @@
</tr>
<tr>
<td colspan="2">
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{@getUrl('act','')}'" />
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{getUrl('act','')}'" />
<input type="submit" value="{$lang->cmd_registration}" accesskey="s" />
</td>
</tr>

View file

@ -24,7 +24,7 @@
</tr>
<tr>
<td colspan="2">
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{@getUrl('act','')}'" />
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{getUrl('act','')}'" />
<input type="submit" value="{$lang->cmd_registration}" accesskey="s" />
</td>
</tr>

View file

@ -26,7 +26,7 @@
</tr>
<tr>
<td colspan="2">
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{@getUrl('act','')}'" />
<input type="button" value="{$lang->cmd_cancel}" onclick="location.href='{getUrl('act','')}'" />
<input type="submit" value="{$lang->cmd_registration}" accesskey="s" />
</td>
</tr>