Support Team 
注册日期: 2004/6/29 20:25
所属群组:
注册会员 技术文档组 ComSupp ComSupp
等级: 11; EXP: 42 HP: 0 / 260 MP: 51 / 5342
|
此主题在xoops-2.3.3的默认主题zetagenesis的基础上修改而成,因此命名为zetagenesis2。 特性: 1. 将传统的xoops导航菜单以水平菜单(含子菜单)的形式呈现。 2. 此主题和系统代码的偶合度很低,不需要修改主题目录以外的任何文件。 3. 完全的权限及管理功能支持: a) 对guest用户将只显示用户管理主菜单。用户登陆后将显示编辑帐号、用户搜索、更改密码等相应的子菜单。 b) 通过在模块管理中将模块排列顺序设为0, 可将相应的模块菜单隐藏。 4. 根据水平导航菜单的需要,会显示当前访问页面所在模块之外的其它模块的子菜单(注:这和传统的网站导航不同,传统的竖排导航只会显示当前模块的子菜单,而不会展开其它模块的子菜单)。 5. 主题中没有硬编码任何汉字,理论上支持多种语言。 基于xoops-2.3.3所做的修改:
diff --git a/htdocs/themes/zetagenesis/css/pro_dropdown_3.css b/htdocs/themes/zetagenesis/css/pro_dropdown_3.css
new file mode 100644
index 0000000..64a9016
--- /dev/null
+++ b/htdocs/themes/zetagenesis/css/pro_dropdown_3.css
@@ -0,0 +1,145 @@
+/* ================================================================
+This copyright notice must be kept untouched in the stylesheet at
+all times.
+
+The original version of this stylesheet and the associated (x)html
+is available at http://www.stunicholls.com/menu/pro_dropdown_3.html
+Copyright (c) 2005-2007 Stu Nicholls. All rights reserved.
+This stylesheet and the associated (x)html may be modified in any
+way to fit your requirements.
+=================================================================== */
+
+.default_preload1 {/*background: url(three_0a.gif);*/}
+.default_preload2 {/*background: url(three_1a.gif);*/}
+
+#default_nav {
+ padding:0;
+ margin:0;
+ height:30px;
+ min-height:30px;
+ background:#846add url(../img/navbar-bg.png) repeat-x left bottom; /*#846add*/
+ color:#fff;
+ font-size:1.1em;
+ text-align:center;
+ list-style-type:none;
+ position:relative;
+ z-index:500;
+}
+
+#default_nav li.default_top {display:block; float:left;}
+#default_nav li a.default_top_link {
+display:block;
+float:left;
+height:23px;
+line-height:20px;
+color:#fff;
+text-decoration:none;
+font-size:11px;
+font-weight:bold;
+padding:0 0 0 12px;
+cursor:pointer;
+/*background-color:#ddd;*/
+/*background: url(three_0.gif);*/
+}
+#default_nav li a.default_top_link span {
+float:left;
+display:block;
+padding:0 24px 0 12px;
+height:23px;
+/*background: url(three_0.gif) right top no-repeat;*/
+}
+#default_nav li a.default_top_link span.default_down {
+float:left;
+display:block;
+padding:0 24px 0 12px;
+height:23px;
+background: url(../img/arrow_down_white.gif) 90% 50% no-repeat;
+}
+
+#default_nav li:hover a.default_top_link, #default_nav li a.default_selected {color:#846add; background-color:#ddd; border-bottom:3px solid #846add;}
+#default_nav li:hover a.default_top_link span, #default_nav li a.default_selected span {background-color:#ddd;}
+#default_nav li:hover a.default_top_link span.default_down, #default_nav li a.default_selected span.default_down {background-color:#ddd; background: url(../img/arrow_down_purple.gif) 90% 50% no-repeat;}
+
+/* Default list styling */
+
+#default_nav li:hover {position:relative; z-index:200;}
+
+#default_nav li:hover ul.default_sub
+{left:1px; top:26px; background-color: #846add; color:#fff; white-space:nowrap; width:auto; height:auto; z-index:300;}
+
+#default_nav li:hover ul.default_sub li
+{display:block; height:23px; position:relative; float:left; width:100%; text-align: left; font-size:11px; font-weight:bold;}
+#default_nav li:hover ul.default_sub li a
+{display:block; font-size:11px; height:23px; width:100%; background-color: #846add; color:#fff; line-height:20px; padding:0 5px; text-decoration:none;}
+#default_nav li ul.default_sub li a.default_fly
+{background:#e9e9e9 url(../img/arrow.gif) 80px 6px no-repeat;}
+#default_nav li:hover ul.default_sub li a:hover
+{background-color: #ddd; color:#846add;}
+#default_nav li:hover ul.default_sub li a.default_fly:hover
+{background:#c6c7c9 url(../img/arrow_over.gif) 80px 6px no-repeat; color:#fff;}
+
+/*couleur des titres dans les menus déroulés*/
+#default_nav li b {display:block; font-size:11px; height:18px; width:88px; line-height:18px; margin-bottom:3px; text-indent:6px; color:#000; border-bottom:1px solid #000; cursor:default;}
+
+#default_nav li:hover li:hover ul,
+#default_nav li:hover li:hover li:hover ul,
+#default_nav li:hover li:hover li:hover li:hover ul,
+#default_nav li:hover li:hover li:hover li:hover li:hover ul
+{left:90px; top:-4px; background: #e9e9e9; padding:3px; border:1px solid #0b4d97; white-space:nowrap; width:90px; z-index:400; height:auto;}
+
+#default_nav ul,
+#default_nav li:hover ul ul,
+#default_nav li:hover li:hover ul ul,
+#default_nav li:hover li:hover li:hover ul ul,
+#default_nav li:hover li:hover li:hover li:hover ul ul
+{position:absolute; left:-9999px; top:-9999px; width:0; height:0; margin:0; padding:0; list-style:none;}
+
+#default_nav li:hover li:hover a.default_fly,
+#default_nav li:hover li:hover li:hover a.default_fly,
+#default_nav li:hover li:hover li:hover li:hover a.default_fly,
+#default_nav li:hover li:hover li:hover li:hover li:hover a.default_fly
+{background:#c6c7c9 url(../img/arrow_over.gif) 80px 6px no-repeat; color:#fff; border-color:#fff;}
+
+#default_nav li:hover li:hover li a.default_fly,
+#default_nav li:hover li:hover li:hover li a.default_fly,
+#default_nav li:hover li:hover li:hover li:hover li a.default_fly
+{background:#e9e9e9 url(../img/arrow.gif) 80px 6px no-repeat; color:#000; border-color:#e9e9e9;}
+
+
+/*
+#xo-globalnav {
+ min-height: 28px;
+ margin: 0;
+ background: #846add url(../img/navbar-bg.png) repeat-x left bottom;
+ padding: 2px 0 0;
+ color: #fff;
+ font-size: 1.1em;
+ text-align: center;
+ list-style-type: none;
+}
+* html #xo-globalnav {
+ height: 28px;
+}
+
+#xo-globalnav .x2-label {
+ display: none;
+}
+
+#xo-globalnav li {
+ display: inline;
+ margin: 0;
+ padding-left: .5em;
+ padding-right: .5em;
+}
+
+#xo-globalnav a {
+ background-color: inherit;
+ color: #fff;
+ text-decoration: none;
+}
+
+#xo-globalnav a:hover {
+ background-color: inherit;
+ color: #b3aaec;
+ text-decoration: none;
+}*/
diff --git a/htdocs/themes/zetagenesis/ex_assign.php b/htdocs/themes/zetagenesis/ex_assign.php
new file mode 100644
index 0000000..f507e12
--- /dev/null
+++ b/htdocs/themes/zetagenesis/ex_assign.php
@@ -0,0 +1,51 @@
+<?php
+
+global $xoopsUser, $xoopsModule;
+if (is_object($xoopsUser)) {
+ $pm_handler =& xoops_gethandler('privmessage');
+
+ $criteria = new CriteriaCompo(new Criteria('read_msg', 0));
+ $criteria->add(new Criteria('to_userid', $xoopsUser->getVar('uid')));
+ $this->assign("ex_new_messages", $pm_handler->getCount($criteria));
+}
+
+require_once XOOPS_ROOT_PATH.'/modules/system/blocks/system_blocks.php';
+function get_system_main_menu_show()
+{
+ global $xoopsUser,$xoopsModule;
+ $block = array();
+ $block['lang_home'] = _MB_SYSTEM_HOME;
+ $block['lang_close'] = _CLOSE;
+ $module_handler =& xoops_gethandler('module');
+ $criteria = new CriteriaCompo(new Criteria('hasmain', 1));
+ $criteria->add(new Criteria('isactive', 1));
+ $criteria->add(new Criteria('weight', 0, '>'));
+ $modules = $module_handler->getObjects($criteria, true);
+ $moduleperm_handler =& xoops_gethandler('groupperm');
+ $groups = is_object($xoopsUser) ? $xoopsUser->getGroups() : XOOPS_GROUP_ANONYMOUS;
+ $read_allowed = $moduleperm_handler->getItemIds('module_read', $groups);
+ foreach (array_keys($modules) as $i) {
+ if (in_array($i, $read_allowed)) {
+ $block['modules'][$i]['name'] = $modules[$i]->getVar('name');
+ $block['modules'][$i]['directory'] = $modules[$i]->getVar('dirname');
+ $sublinks = $modules[$i]->subLink();
+ if ((count($sublinks) > 0) ) {
+ foreach($sublinks as $sublink){
+ $block['modules'][$i]['sublinks'][] = array('name' => $sublink['name'], 'url' => XOOPS_URL.'/modules/'.$modules[$i]->getVar('dirname').'/'.$sublink['url']);
+ }
+ } else {
+ $block['modules'][$i]['sublinks'] = array();
+ }
+ }
+ }
+ return $block;
+}
+
+$MainMenu = get_system_main_menu_show();
+$this->assign( 'ex_mainmenu', $MainMenu );
+if ( is_object($xoopsModule) ) {
+ $this->assign('ex_moduledir', $xoopsModule->getVar('dirname'));
+ $this->assign('ex_module_name', $xoopsModule->getVar('name') );
+}
+
+?>
diff --git a/htdocs/themes/zetagenesis/img/arrow.gif b/htdocs/themes/zetagenesis/img/arrow.gif
new file mode 100644
index 0000000..88c0c1f
Binary files /dev/null and b/htdocs/themes/zetagenesis/img/arrow.gif differ
diff --git a/htdocs/themes/zetagenesis/img/arrow_down_purple.gif b/htdocs/themes/zetagenesis/img/arrow_down_purple.gif
new file mode 100644
index 0000000..aaba52c
Binary files /dev/null and b/htdocs/themes/zetagenesis/img/arrow_down_purple.gif differ
diff --git a/htdocs/themes/zetagenesis/img/arrow_down_white.gif b/htdocs/themes/zetagenesis/img/arrow_down_white.gif
new file mode 100644
index 0000000..36a17c9
Binary files /dev/null and b/htdocs/themes/zetagenesis/img/arrow_down_white.gif differ
diff --git a/htdocs/themes/zetagenesis/img/arrow_over.gif b/htdocs/themes/zetagenesis/img/arrow_over.gif
new file mode 100644
index 0000000..d9a43de
Binary files /dev/null and b/htdocs/themes/zetagenesis/img/arrow_over.gif differ
diff --git a/htdocs/themes/zetagenesis/language/schinese_utf8/main.php b/htdocs/themes/zetagenesis/language/schinese_utf8/main.php
new file mode 100644
index 0000000..680ebd3
--- /dev/null
+++ b/htdocs/themes/zetagenesis/language/schinese_utf8/main.php
@@ -0,0 +1,19 @@
+<?php
+
+// Theme language definitions
+
+// $Id: main.php 2857 2009-02-22 18:12:11Z dugris $
+// _LANGCODE: en
+// _CHARSET : UTF-8
+// Translator: XOOPS Translation Team
+
+/* ------------------- userbar.html ------------------- */
+define("_THEME_REGISTER", "泚册");
+define("_THEME_INBOX", "æ”¶ä»¶ç®±");
+define("_THEME_INBOX_NOTREAD", "未读消�");
+define("_THEME_NOTIFICATIONS", "通知");
+define("_THEME_PROFILE", "查看��");
+define("_THEME_ADMINISTRATION", "管�区");
+define("_THEME_LOGOUT", "退出");
+
+?>
diff --git a/htdocs/themes/zetagenesis/language/schinese_utf8/script.js b/htdocs/themes/zetagenesis/language/schinese_utf8/script.js
new file mode 100644
index 0000000..60e8934
--- /dev/null
+++ b/htdocs/themes/zetagenesis/language/schinese_utf8/script.js
@@ -0,0 +1,2 @@
+/* $Id$ */
+/* Localization script */
No newline at end of file
diff --git a/htdocs/themes/zetagenesis/language/schinese_utf8/style.css b/htdocs/themes/zetagenesis/language/schinese_utf8/style.css
new file mode 100644
index 0000000..afdff59
--- /dev/null
+++ b/htdocs/themes/zetagenesis/language/schinese_utf8/style.css
@@ -0,0 +1,2 @@
+/* $Id$ */
+/* Localization stylesheet */
No newline at end of file
diff --git a/htdocs/themes/zetagenesis/stuHover.js b/htdocs/themes/zetagenesis/stuHover.js
new file mode 100644
index 0000000..93f9f95
--- /dev/null
+++ b/htdocs/themes/zetagenesis/stuHover.js
@@ -0,0 +1,35 @@
+/* ================================================================
+This copyright notice must be kept untouched in the stylesheet at
+all times.
+
+The original version of this script and the associated (x)html
+is available at http://www.stunicholls.com/menu/pro_drop_1.html
+Copyright (c) 2005-2007 Stu Nicholls. All rights reserved.
+This script and the associated (x)html may be modified in any
+way to fit your requirements.
+=================================================================== */
+stuHover = function() {
+ var cssRule;
+ var newSelector;
+ for (var i = 0; i < document.styleSheets.length; i++)
+ for (var x = 0; x < document.styleSheets[i].rules.length ; x++)
+ {
+ cssRule = document.styleSheets[i].rules[x];
+ if (cssRule.selectorText.indexOf("LI:hover") != -1)
+ {
+ newSelector = cssRule.selectorText.replace(/LI:hover/gi, "LI.iehover");
+ document.styleSheets[i].addRule(newSelector , cssRule.style.cssText);
+ }
+ }
+ var getElm = document.getElementById("default_nav").getElementsByTagName("LI");
+ for (var i=0; i<getElm.length; i++) {
+ getElm[i].onmouseover=function() {
+ this.className+=" iehover";
+ }
+ getElm[i].onmouseout=function() {
+ this.className=this.className.replace(new RegExp(" iehover\b"), "");
+ }
+ }
+}
+if (window.attachEvent) window.attachEvent("onload", stuHover);
+
diff --git a/htdocs/themes/zetagenesis/theme.html b/htdocs/themes/zetagenesis/theme.html
index 95ca8fe..28371fa 100644
--- a/htdocs/themes/zetagenesis/theme.html
+++ b/htdocs/themes/zetagenesis/theme.html
@@ -12,6 +12,7 @@
<{assign var=theme_plugin value=$xoTheme->folderName|cat:'/xoplugins'}>
<!-- Metas, Titles, and Style Sheets -->
<{includeq file="$theme_name/xometas.html"}>
+ <{include_php file="$xoops_rootpath/themes/$xoops_theme/ex_assign.php"}>
<!-- Additionals Scripts -->
<{includeq file="$theme_name/xoscripts.html"}>
</head>
@@ -73,4 +74,4 @@
</div>
</body>
-</html>
No newline at end of file
+</html>
diff --git a/htdocs/themes/zetagenesis/xotpl/globalnav.html b/htdocs/themes/zetagenesis/xotpl/globalnav.html
index 68812ea..ce787dc 100644
--- a/htdocs/themes/zetagenesis/xotpl/globalnav.html
+++ b/htdocs/themes/zetagenesis/xotpl/globalnav.html
@@ -1,3 +1,52 @@
-<div id="xo-globalnav" class="x2-nl x2-navigation">
- <ul><li class="x2-label">Main navigation</li></ul>
-</div>
No newline at end of file
+
+<span class="default_preload1"></span>
+<span class="default_preload2"></span>
+<ul id="default_nav">
+<!-- 䞻页��项匀始 -->
+<li class="default_top">
+<{if ! $ex_moduledir || $xoops_dirname == "pm" }>
+ <a href="<{$xoops_url}>" class="default_top_link default_selected" target="_self" alt="<{$smarty.const._MB_SYSTEM_HOME}>" title="<{$smarty.const._MB_SYSTEM_HOME}>">
+<{else}>
+ <a href="<{$xoops_url}>" class="default_top_link" target="_self" alt="<{$smarty.const._MB_SYSTEM_HOME}>" title="<{$smarty.const._MB_SYSTEM_HOME}>">
+<{/if}>
+ <span> <{$smarty.const._MB_SYSTEM_HOME}> </span>
+</a>
+</li>
+<!-- 䞻页��项结� -->
+
+<!-- 暡���项匀始 -->
+ <{foreach item=module from=$ex_mainmenu.modules }>
+ <li class="default_top">
+ <{if $module.directory == $ex_moduledir }>
+ <a href="<{$xoops_url}>/modules/<{$module.directory}>/" class="default_top_link default_selected" target="_self" alt="<{$module.name}>" title="<{$module.name}>" >
+ <{if $module.sublinks }>
+ <span class="default_down"> <{$module.name}> </span> </a>
+ <ul class="default_sub">
+ <{foreach item=sublink from=$module.sublinks}>
+ <li >
+ <a href="<{$sublink.url}>" target="_self" alt="<{$sublink.name}>" title="<{$sublink.name}>"><{$sublink.name}></a>
+ </li>
+ <{/foreach}>
+ </ul>
+ <{else}>
+ <span> <{$module.name}> </span> </a>
+ <{/if}>
+ <{else}>
+ <a href="<{$xoops_url}>/modules/<{$module.directory}>/" class="default_top_link" target="_self" alt="<{$module.name}>" title="<{$module.name}>" >
+ <{if $module.sublinks }>
+ <span class="default_down"> <{$module.name}> </span> </a>
+ <ul class="default_sub">
+ <{foreach item=sublink from=$module.sublinks}>
+ <li >
+ <a href="<{$sublink.url}>" target="_self" alt="<{$sublink.name}>" title="<{$sublink.name}>"><{$sublink.name}></a>
+ </li>
+ <{/foreach}>
+ </ul>
+ <{else}>
+ <span> <{$module.name}> </span> </a>
+ <{/if}>
+ <{/if}>
+ </li>
+ <{/foreach}>
+</ul>
+<!-- 暡���项结� -->
diff --git a/htdocs/themes/zetagenesis/xotpl/xometas.html b/htdocs/themes/zetagenesis/xotpl/xometas.html
index 92cdf7c..a63e611 100644
--- a/htdocs/themes/zetagenesis/xotpl/xometas.html
+++ b/htdocs/themes/zetagenesis/xotpl/xometas.html
@@ -27,4 +27,4 @@
<link rel="stylesheet" type="text/css" media="all" href="<{xoImgUrl css/layout-soup.css}>" />
<link rel="stylesheet" type="text/css" media="all" title="Color" href="<{xoImgUrl css/style.css}>" />
-<{$xoops_module_header}>
No newline at end of file
+<{$xoops_module_header}>
diff --git a/htdocs/themes/zetagenesis/xotpl/xoscripts.html b/htdocs/themes/zetagenesis/xotpl/xoscripts.html
index e1faa25..90fd6cd 100644
--- a/htdocs/themes/zetagenesis/xotpl/xoscripts.html
+++ b/htdocs/themes/zetagenesis/xotpl/xoscripts.html
@@ -14,4 +14,12 @@ img {
padding-top: 2px;
}
</style>
-<![endif]-->
No newline at end of file
+<script type="text/javascript" src="<{xoImgUrl dropdowntabfiles/dropdowntabs.js}"></script>
+<link rel="stylesheet" type="text/css" href="<{xoImgUrl dropdowntabfiles/bluetabs.css}" />
+
+<![endif]-->
+<style type="text/css">
+#xo-canvas-rightcolumn .xo-block { width: 200px; } /* add by kris */
+</style>
+<script src="<{xoImgUrl stuHover.js}>" type="text/javascript"> </script>
+<link rel="stylesheet" type="text/css" media="all" href="<{xoImgUrl css/pro_dropdown_3.css}>" />
用法: 下载附件 zetagenesis2.tar.gz 文件,并解压到themes目录中,然后设置网站的风格主题为zetagenesis2。 下载链接: http://xoops.org.cn/modules/wfdownloads/visit.php?cid=6&lid=665
附件:
screenshot.png (122.07 KB)
2010/1/2 21:11
|