www.zghnqyw.org<script language=javascript>
var Showed_TabId;
function Hide_Template(Ids)
{
var AIds=Ids.split(',');
for(i=0;i<AIds.length;i++)
{
document.getElementById("Template_"+AIds
).style.display="none";
}
}
function Load_Template_Content(FromId,ToId)
{
document.getElementById("Template_Content_"+ToId).innerHTML=document.getElementById("Template_Content_"+FromId).innerHTML;
Showed_TabId=FromId;
}
自定义样式
function ShowTab(Id,ToId)
{
document.getElementById("Tab_"+Showed_TabId).className="template_tab_title_1";
document.getElementById("Tab_"+Id).className="template_tab_title";
Load_Template_Content(Id,ToId);
}
</script>
<style type="text/css">
.template_tab_title{float:left;text-align:center;width:100px;height:21px;padding-top:5px;background:red no-repeat left bottom;font-weight:bold;color
ffffff;cursor:pointer}
.template_tab_title_1{float:left;text-align:center;width:100px;height:21px;padding-
top:5px;background
reen no-repeat left bottom;cursor:pointer}
.template_tab_title_right{float:right;padding-top:5px;}
</style>
<ul style="width: 100%">
<li class="template_tab_title" id="Tab_114" onmouseover="ShowTab('114','113');">校园新闻</li>
<li class="template_tab_title_1" id="Tab_115" style="margin-left: 5px" onmouseover="ShowTab('115','113');">百度</li>
<li class="template_tab_title_1" id="Tab_116" style="margin-left: 5px" onmouseover="ShowTab('116','113');">谷歌</li>
<li class="template_tab_title_1" id="Tab_117" style="margin-left: 5px" onmouseover="ShowTab('117','113');">狗狗</li>
<li class="template_tab_title_right"><a href="#">更多...</a> </li>
</ul>
内容设置
<script type="text/javascript">
Hide_Template("114,115,116,117");
Load_Template_Content("115","113");
</script>
114 115 116 117 为模块编号
113为自定义选项卡编号