<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <title>教学管理系统</title> <style type="text/css"> .student_picture{ border-radius:100%; border:0px; } .school_picture{ width:50px; height:50px; border-radius:100%; border:1px; } body { background-color: #F5DEB3 } table { /*表格边框为实线或者是空心双线*/ border-collapse: collapse; /*边框与边框的空间*/ border-spacing: 0; } a { color: rgb(60, 114, 53); text-decoration: none; font-size: 12px; } a:hover { color: rgb(60, 114, 53); text-decoration: underline; font-size: 12px; } a:visited { color: rgb(0, 106, 78); font-size: 12px; } /*整个tab层居中,宽度为600px*/ #tabDiv { background: rgb(176,196,222); FILTER:alpha(opacity=40); } /*tab头的样式*/ #tabsHead { padding-left: 0px; height: 26px; background-color: rgb(179, 247, 19); font-size: 1em; color: rgb(179, 247, 19); line-height: 26px; } /*已选tab头(超链接)的样式*/ .curtab { padding-top: 0px; padding-right: 10px; padding-bottom: 0px; padding-left: 10px; border-right: rgb(209, 226, 49) 1px solid; font-weight: bold; float: left; cursor: pointer; background: #ffffff; } /*未选tab头(超链接)的样式*/ .tabs { border-right: rgb(209, 226, 49) 1px solid; padding-top: 0px; padding-right: 10px; padding-bottom: 0px; padding-left: 10px; font-weight: normal; float: left; cursor: pointer; } p { font-size: 12pt; text-indent: 2em; } li { border-bottom-style: solid; border-bottom-color: #EEE; border-bottom-width: thin; height: 25px; font-family: "宋体"; font-size: 20pt; } </style> <script type="text/jscript"> //显示tab(tabHeadId:tab头中当前的超链接;tabContentId要显示的层ID) function showTab(tabHeadId,tabContentId) { //tab层 var tabDiv = document.getElementById("tabDiv"); //将tab层中所有的内容层设为不可见 //遍历tab层下的所有子节点 var taContents = tabDiv.childNodes; for(i=0; i<taContents.length; i++) { //将所有内容层都设为不可见 if(taContents[i].id!=null && taContents[i].id != 'tabsHead') { taContents[i].style.display = 'none'; } } //将要显示的层设为可见 document.getElementById(tabContentId).style.display = 'block'; //遍历tab头中所有的超链接 var tabHeads = document.getElementById('tabsHead').getElementsByTagName('a'); for(i=0; i<tabHeads.length; i++) { //将超链接的样式设为未选的tab头样式 tabHeads[i].className='tabs'; } //将当前超链接的样式设为已选tab头样式 document.getElementById(tabHeadId).className='curtab'; document.getElementById(tabHeadId).blur(); } </script> </head> <% String a=request.getParameter("a"); if(a==null){ a="1"; } %> <body> <table id="tabDiv" border="1" style="font-size:18px;width:1460px;"> <tr><td style="width:40px;height:40px;" align="center" > <img src="school.png" class="school_picture" > </td> <td style="width:240px;height:40px;"> <%out.print("欢迎石家庄铁道大学的管理员"); %> </td> <td style="width:200px;height:40px;cursor: pointer" align="center" id="executive"> 行政管理 </td> <td style="width:200px;height:40px;cursor: pointer" align="center" id="lesson"> 课程管理 </td> <td style="width:200px;height:40px;cursor: pointer;" align="center" id="wifi"> 网课管理 </td> <td style="width:200px" align="center"> <font color="red">管理员:<%out.print("54188"); %></font> <a href="Login.jsp"><button>退出登陆</button></a> </td> </tr> </table> <%if(a.equals("1")) {%> <br><br> <table style="width:1460px;font-size:18px;height:600px;" border="1" id="tabDiv"> <tr> <td align="center" style="cursor:pointer" id="Select_user">浏览用户 </td><td align="center" style="cursor:pointer" id="Add_user">增添用户</td> </tr> </table> <script type="text/javascript"> var Select_user=document.getElementById('Select_user'); var Add_user=document.getElementById('Add_user'); Select_user.onclick=function(){ window.location.href='Select_user.jsp'; } Add_user.onclick=function(){ window.location.href='Add_user.jsp'; } </script> <%} else if(a.equals("2")){ %> <br><br> <table style="width:1460px;font-size:18px;height:600px;" border="1" id="tabDiv"> <tr> <td align="center" style="cursor:pointer" id="a">批阅课程 </td> <td align="center" style="cursor:pointer" id="b">排班</td> </tr> <tr> <td align="center" style="cursor:pointer" id="c">浏览课程 </td> <td align="center" style="cursor:pointer" id="d">浏览实验</td> </tr> </table> <script type="text/javascript"> var a=document.getElementById('a'); var b=document.getElementById('b'); var c=document.getElementById('c'); var d=document.getElementById('d'); a.onclick=function(){ window.location.href='Browse_Audit.jsp?identity=Root'; } b.onclick=function(){ alert('该功能尚未开发'); } c.onclick=function(){ window.location.href='Browse_lesson.jsp?identity=Root'; } d.onclick=function(){ window.location.href='Browse_experiment.jsp?identity=Root'; } </script> <%} else{%> <%} %> <script type="text/javascript"> var executive=document.getElementById('executive'); var lesson=document.getElementById('lesson'); var wifi=document.getElementById('wifi'); executive.onclick=function(){ window.location.href='all_Root.jsp?a=1'; } lesson.onclick=function(){ window.location.href='all_Root.jsp?a=2'; } wifi.onclick=function(){ alert('该功能尚未开发完毕'); } </script> </body> </html>
标签:function,document,博客,font,getElementById,23.4,var,团队,border From: https://www.cnblogs.com/kaixingaoxing/p/17293701.html