经提示:
恭喜您!顶部菜单成功生成,请按以下提示完成最好操作。
第一步:将以下代码复制到您要调用模板的<head></head>之间。
<script language="javascript" type="text/javascript" src="/ks_inc/stm31.js"></script>
第二步:将以下代码复制到在模板里要显示的地方。
<script language="javascript" type="text/javascript" src="/JS/Menu.js"></script>
新人刚学CMS,,,我将两个代码都分别按提示去试了,,,,插在首页模板上都没反应,,,,请高手指点下~~~
-----------------------------------------------------------------------------------------------------------------------------------------
首页的代码,告诉我具体插入到哪个位置?
<html>
<head><title>{$GetSiteName}</title>
<meta http-equiv=Content-Type content="text/html; charset=GBK">
<link href="{$GetInstallDir}images/index.css" type=text/css rel=stylesheet>
<meta http-equiv=X-UA-Compatible content=IE=EmulateIE7>
<SCRIPT type=text/javascript>
function show(i)
{
if (i.style.display == "none") {
i.style.display = "";
}else{
i.style.display = "none";
}
}
function scrollDoor(){
}
scrollDoor.prototype = {
sd : function(menus,divs,openClass,closeClass){
var _this = this;
if(menus.length != divs.length)
{
alert("菜单层数量和内容层数量不一样!");
return false;
}
for(var i = 0 ; i < menus.length ; i++)
{
_this.$(menus[i]).value = i;
_this.$(menus[i]).onmouseover = function(){
for(var j = 0 ; j < menus.length ; j++)
{
_this.$(menus[j]).className = closeClass;
_this.$(divs[j]).style.display = "none";
}
_this.$(menus[this.value]).className = openClass;
_this.$(divs[this.value]).style.display = "block";
}
}
},
$ : function(oid){
if(typeof(oid) == "string")
return document.getElementById(oid);
return oid;
}
}
window.onload = function(){
var SDmodel = new scrollDoor();
SDmodel.sd(["m03","m04"],["c03","c04"],"sd03","sd04");
}
</SCRIPT>
</head>
<body contentEditable=true>
<div align=center>
<div id=topdiv>
<div id=topper>
<div id=datediv><img src="{$GetInstallDir}images/taiyang.gif" align=absMiddle>今天是:
{$JS_Time2}</div>
<div id=icon01><img src="{$GetInstallDir}images/m_list_49.gif" align=absMiddle></div>
<div id=logondiv>{$GetTopUserLogin}</div>
<div id=makehome><img src="{$GetInstallDir}images/home.gif" align=absMiddle>{$JS_HomePage}
<img src="{$GetInstallDir}images/email.gif" align=absMiddle> {$JS_Collection} <img
src="{$GetInstallDir}images/ic_chan.gif" align=absMiddle> {$JS_Language}</div>
<div class=clear></div></div></div></div>
<div align=center>
<div class=header><img alt="" src="{$GetInstallDir}UploadFiles/2010052012003684714.jpg"
border=0></div></div>
<div align=center>
<div class=clear></div></div>
<div align=center>
<div class=menu>
<div class=nav>
<ul>
<li><a class=blue-bg href="{$GetInstallDir}">网站首页</a> {LB_频道导航}
</li></ul></div></div></div>
<div align=center>
<div class=sea style="WIDTH: 951px; HEIGHT: 15px">
<div class=search>
<div class=sp_sea_l style="WIDTH: 499px; HEIGHT: 40px">
<p align=left>{$GetSearch}</p></div>
<div class=sp_sea_r style="WIDTH: 444px; HEIGHT: 35px">
<div class=spnum style="WIDTH: 154px; HEIGHT: 48px">购物车共有<font color=#ff0101><script
src="{$GetInstallDir}shop/ShowShoppingCartNum.asp"></script></font>件商品</div>
<div class=s_btn1><a href="{$GetInstallDir}shop/pack.asp?id=1" target=_blank>自选礼包
</a></div>
<div class=s_btn2><a href="{$GetInstallDir}User/">我的账户</a></div></div></div></div></div>
<div align=center>
<div class=clear></div></div>
<!-- 顶部结束 -->
<div align=center><a href="{$GetInstallDir}shop/pack.asp?id=1" target=_blank><img
style="WIDTH: 950px; HEIGHT: 44px" height=49 src="{$GetInstallDir}images/eshop/sxx.png"
width=950></a></div>
<div align=center>
<div class=clear></div></div>
<div align=center>
<div class=shop_main1>
<div class=shop_main1_l>
<div class=shop_main1_1box>
<STYLE type=text/css>
.preview {padding:0px;overflow:hidden;width:225px;}
.scrolldoorFrame{width:225px;margin:0px auto;overflow:hidden;}
.scrollUl {float:left;overflow:hidden;height:29px; padding-left:4px;}
.scrollUl li {float:left;}
.bor03 {float:left;width:220px;}
.sd03{cursor:pointer; width:96px; height:29px;margin-left:4px; background:url
({$GetInstallDir}images/btn1.jpg) no-repeat; color:#404040; font-weight:bold; font-
size:12px; line-height:29px; text-align: center;}
.sd04{cursor:pointer; width:96px; height:29px; margin-left:4px; color:#404040; font-
size:12px; background:url({$GetInstallDir}images/btn2.jpg) no-repeat; line-height:29px;
text-align: center;}
</STYLE>
<div class=preview>
<div class=scrolldoorFrame>
<ul class=scrollUl>
<li class=sd04 id=m03>商品分类 </li>
<li class=sd03 id=m04 value=1>品牌分类 </li></ul>
<div class="bor03 shop_main1_box">
<div id=c03 style="DISPLAY: none; FLOAT: left"><script language="javascript"
type="text/javascript" src="{$GetInstallDir}JS/shop.js"></script> </div>
<div class=hidden id=c04 style="DISPLAY: block"><script language="javascript"
type="text/javascript" src="{$GetInstallDir}JS/Brand.js"></script>
</div></div></div></div></div>
<div class=shop_main1_2box>
<div class=shop_main1_tit>推荐商品</div>
<div class=shop_main1_box>{LB_推荐商品} </div></div></div>
<div class=shop_main1_r>
<div class=shop_main1_rl>
<div class=sp_flash>{LB_商品幻灯}</div>
<div class=clear></div>
<div class=sp_qg> </div></div>
<div class=shop_main1_rr><img src="{$GetInstallDir}images/a_r1_c1.gif"><br /><img
src="{$GetInstallDir}images/a_r3_c1.gif"><br /><img src="{$GetInstallDir}
images/a_r5_c1.gif"><br /><img src="{$GetInstallDir}images/a_r7_c1.gif"><br />
<div class=clear></div>
<div class=shop_main1_rr2>
<div class=shop_main1_tit>商城公告</div>
<div class=shop_main1_rbox>{LB_商城公告} </div></div></div>
<div class=clear></div>
<div class=shop_main2>
<div class=shop_main2_tit>最新商品</div>
<div class=duc>
<ul class=midd_du>{LB_最新商品} </ul></div></div>
<div class=clear></div>
<div class=shop_main2>
<div class=shop_main2_tit>特价商品</div>
<div class=duc>
<ul class=midd_du>{LB_特价商品} </ul></div></div></div></div></div>
<div align=center>
<div class=clear></div></div>
<div align=center>
<div class=Help>
<DL>
<DT><img height=32 alt=购物指南 src="{$GetInstallDir}images/eshop/help_gwzn.gif" width=113>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>购物流程</a>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>会员介绍</a>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>订单状态</a>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>常见问题</a>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>大 家 电</a>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>联系客服</a> </DD></DL>
<DL>
<DT><img height=32 alt=配送方式 src="{$GetInstallDir}images/eshop/help_psfs.gif" width=114>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>上门自提</a>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>快递运输</a>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>邮局普包</a>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>特快专递(EMS)</a>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>中铁快运</a> </DD></DL>
<DL>
<DT><img height=32 alt=支付方式 src="{$GetInstallDir}images/eshop/help_zffs.gif" width=111>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>货到付款</a>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>在线支付</a>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>银行转账</a>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>分期付款</a>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>邮局汇款</a>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>公司转账</a> </DD></DL>
<DL>
<DT><img height=32 alt=售后服务 src="{$GetInstallDir}images/eshop/help_shfw.gif" width=110>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>退换货政策</a>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>退换货流程</a>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>价格保护</a> </DD></DL>
<DL class=Help_b5>
<DT><img height=32 alt=特色服务 src="{$GetInstallDir}images/eshop/help_tsfw.gif" width=113>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>商品拍卖</a>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>DIY装机</a>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank><font color=red>延保服务</font></a>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>上门服务</a>
<DD><img src="{$GetInstallDir}images/ico01.gif"><a href="{$GetInstallDir}shop/ShopHelp.asp"
target=_blank>上门装机</a> </DD></DL></div></div>
<div align=center> </div>
<p align=center>{LB_底部通用} </p>
<div class=clear style="WIDTH: 965px; HEIGHT: 1px"></div></body>
<html>