Top.jsp~647~
上传用户:zghglow
上传日期:2022-08-09
资源大小:27227k
文件大小:8k
源码类别:

WEB源码(ASP,PHP,...)

开发平台:

JavaScript

  1. <%@ page contentType="text/html; charset=GBK" %>
  2. <%@ taglib uri="../WEB-INF/Letter.tld" prefix="l" %>
  3. <script type="text/javascript">
  4. function Search(){
  5.   var form = document.getElementById("form1");
  6.   form.action = "<%=request.getContextPath()%>/Index.do?todo=SearchIndex";
  7.   form.submit();
  8. }
  9. function CreateMenu(obj,id){
  10.     var url = '<%=request.getContextPath()%>/Index.do?todo=ShowMenu&key=' + id;
  11.     var xmlhttp;
  12.     if(typeof XMLHttpRequest == "undefined" && window.ActiveXObject){
  13.       xmlhttp = new ActiveXObject("Microsoft.xmlHTTP");
  14.     }else{
  15.       xmlhttp = new XMLHttpRequest();
  16.     }
  17.     xmlhttp.open("post",url,true);
  18.     xmlhttp.onreadystatechange = function(){
  19.       CreateMenu_CallBack(xmlhttp,obj,id);
  20.     };
  21.     xmlhttp.setRequestHeader("Content-Type","application/x-www-form-urlencoded");
  22.     xmlhttp.send(null);
  23. }
  24. function ShowMenu(obj,id){
  25.   if(document.getElementById("F" + id) != null){
  26.     document.getElementById("F" + id).style.display = "";
  27.   }else{
  28.     CreateMenu(obj,id);
  29.   }
  30. }
  31. function CreateMenu_CallBack(xmlhttp,obj,id){
  32.   if(xmlhttp.readyState == 4){
  33.     if(xmlhttp.status == 0){
  34.     }else if(xmlhttp.status == 200 && xmlhttp.statusText == "OK"){
  35.       var al = eval(xmlhttp.responseText);
  36.       var top = getTop(obj);
  37.       var left = getLeft(obj);
  38.       var fdiv = document.createElement("div");
  39.       fdiv.id = "F" + id;
  40.       fdiv.style.cssText = "";
  41.       for(var i=0;i<al.length;i++){
  42.         var div = document.createElement("div");
  43.         div.style.cssText = "width:82px;height:20px;font-size:12px;background:#F4F4E1;text-align:center;";
  44.         div.innerHTML = "<a href="<%=request.getContextPath()%>/Index.do?todo=OpenIndexMenu&fMenuID=" + al[i].fId + "&cMenuID=" + al[i].cId + "" class="Div_Links">" + al[i].name + "</a>";
  45.         fdiv.appendChild(div);
  46.       }
  47.       fdiv.onmouseout = function(){
  48.         HidMenu(id);
  49.       };
  50.       fdiv.onmouseover = function(){
  51.           ShowMenu();
  52.       };
  53.       document.getElementById("form1").appendChild(fdiv);
  54.       fdiv.style.left = left;
  55.       fdiv.style.top = top + 21;
  56.       fdiv.style.position = "absolute";
  57.     }
  58.   }
  59. }
  60. function HidMenu(id){
  61.   var div = document.getElementById("F" + id);
  62.   if(div != null){
  63.     div.style.display = "none";
  64.   }
  65. }
  66. function getTop(e){
  67.   var t = e.offsetTop
  68.   while(e = e.offsetParent){
  69.     t += e.offsetTop;
  70.   }
  71.   return t;
  72. }
  73. function getLeft(e){
  74.   var l = e.offsetLeft
  75.   while(e = e.offsetParent){
  76.     l += e.offsetLeft;
  77.   }
  78.   return l;
  79. }
  80. </script>
  81. <table width="840" border="0" align="center" cellpadding="0" cellspacing="0">
  82.   <tr>
  83.     <td width="86" rowspan="2"><img src="<%=request.getContextPath()%>/images/Index_Symbol.jpg" width="86" height="79" alt="" /></td>
  84.     <td width="212"><img src="<%=request.getContextPath()%>/images/Index_Symbol_Word.jpg" width="153" height="48" alt="" /></td>
  85.     <td width="542" valign="bottom" style="padding:0 0 5px 190px;"><table width="100%" border="0" cellspacing="0" cellpadding="0">
  86.       <tr>
  87.         <td width="30%">
  88.           <a href='<%=request.getContextPath()%>/Index.do?todo=OpenIndex&Language=EN'><l:out CNLetter="English" ENLetter="英文版"/></a> |
  89.           <a href='<%=request.getContextPath()%>/Index.do?todo=OpenIndex&Language=CN'><l:out CNLetter="中文版" ENLetter="Chinese"/></a> </td>
  90.         <td width="70%"><table width="262" border="0" cellspacing="0" cellpadding="0">
  91.           <tr>
  92.             <td width="66" class="LoginTitle"><l:out CNLetter="站内搜索" ENLetter="Search"/>:</td>
  93.             <td width="170"><input name="condition" type="text" class="input" /></td>
  94.             <td width="26"><img src="<%=request.getContextPath()%>/images/home_06.gif" width="26" height="17" alt="" onclick="Search();" /></td>
  95.           </tr>
  96.         </table></td>
  97.       </tr>
  98.     </table></td>
  99.   </tr>
  100.   <tr>
  101.     <td colspan="2"><table width="100%" border="0" cellspacing="0" cellpadding="0">
  102.       <tr>
  103.         <td><a href="<%=request.getContextPath()%>/Index.do?todo=OpenIndex"><img src="<%=request.getContextPath()%>/images/Index_Home.jpg" width="62" height="21" border="0" alt="" /></a></td>
  104.         <td><a href='<%=request.getContextPath()%>/Index.do?todo=OpenIndexMenu&key=<l:out CNLetter="QYXXCN" ENLetter="QYXXEN" />'><img id="menu01" onmouseover="ShowMenu(this,'QYXX');" onmouseout="HidMenu('QYXX');" src="<%=request.getContextPath()%>/<l:out CNLetter="images" ENLetter="enImages" />/Index_Menu01.jpg" width="82" height="21" border="0" alt="" /></a></td>
  105.         <td><a href='<%=request.getContextPath()%>/Index.do?todo=OpenIndexMenu&key=<l:out CNLetter="QYWHCN" ENLetter="QYWHEN" />'><img id="menu02" onmouseover="ShowMenu(this,'QYWH');" onmouseout="HidMenu('QYWH')" src="<%=request.getContextPath()%>/<l:out CNLetter="images" ENLetter="enImages" />/Index_Menu02.jpg" width="79" height="21" border="0" alt="" /></a></td>
  106.         <td><a href="<%=request.getContextPath()%>/Index.do?todo=OpenIndexMenu&key=<l:out CNLetter="XWGGCN" ENLetter="XWGGEN" />"><img id="menu03" onmouseover="ShowMenu(this,'XWGG');" onmouseout="HidMenu('XWGG')" src="<%=request.getContextPath()%>/<l:out CNLetter="images" ENLetter="enImages" />/Index_Menu03.jpg" width="80" height="21" border="0" alt="" /></a></td>
  107.         <td><a href='<%=request.getContextPath()%>/Index.do?todo=OpenIndexMenu&key=<l:out CNLetter="GDTDCN" ENLetter="GDTDEN" />'><img id="menu04" onmouseover="ShowMenu(this,'GDTD');" onmouseout="HidMenu('GDTD')" src="<%=request.getContextPath()%>/<l:out CNLetter="images" ENLetter="enImages" />/Index_Menu04.jpg" width="76" height="21" border="0" alt="" /></a></td>
  108.         <td><a href='<%=request.getContextPath()%>/Index.do?todo=OpenIndexMenu&key=<l:out CNLetter="SCJYCN" ENLetter="SCJYEN" />'><img id="menu05" onmouseover="ShowMenu(this,'SCJY');" onmouseout="HidMenu('SCJY')" src="<%=request.getContextPath()%>/<l:out CNLetter="images" ENLetter="enImages" />/Index_Menu05.jpg" width="75" height="21" border="0" alt="" /></a></td>
  109.         <td><a href="<%=request.getContextPath()%>/Index.do?todo=OpenIndexMenu&key=<l:out CNLetter="LLZYCN" ENLetter="LLZYEN" />"><img id="menu06" onmouseover="ShowMenu(this,'LLZY');" onmouseout="HidMenu('LLZY')" src="<%=request.getContextPath()%>/<l:out CNLetter="images" ENLetter="enImages" />/Index_Menu06.jpg" width="72" height="21" border="0" alt="" /></a></td>
  110.         <td><a href=""><img src="<%=request.getContextPath()%>/<l:out CNLetter="images" ENLetter="enImages" />/Index_Menu07.jpg" width="72" height="21" border="0" alt="" /></a></td>
  111.         <td><a href="<%=request.getContextPath()%>/Index.do?todo=OpenIndexMenu&key=<l:out CNLetter="WZDTCN" ENLetter="WZDTEN" />"><img id="menu07" onmouseover="ShowMenu(this,'WZDT');" onmouseout="HidMenu('WZDT')" src="<%=request.getContextPath()%>/<l:out CNLetter="images" ENLetter="enImages" />/Index_Menu08.jpg" width="73" height="21" border="0" alt="" /></a></td>
  112.         <td><a href="<%=request.getContextPath()%>/Index.do?todo=ShowContact&fMenuID=<l:out CNLetter="7" ENLetter="61" />"><img src="<%=request.getContextPath()%>/<l:out CNLetter="images" ENLetter="enImages" />/Index_Menu09.jpg" width="75" height="21" border="0" alt="" /></a></td>
  113.         <td><img src="<%=request.getContextPath()%>/images/Index_Menu_Last.jpg" width="8" height="21" alt="" /></td>
  114.       </tr>
  115.       <tr>
  116.         <td colspan="11"><img src="<%=request.getContextPath()%>/images/Index_Menu_Down.jpg" width="754" height="10" alt="" /></td>
  117.       </tr>
  118.     </table></td>
  119.   </tr>
  120. </table>
  121. <table width="840" border="0" align="center" cellpadding="0" cellspacing="0" style="margin-bottom:5px;">
  122.   <tr>
  123.     <td height="3" bgcolor="A40000"></td>
  124.   </tr>
  125. </table>