TabScript 能不能换行 就是放两排,一排6个如果不能
一个页面能不能有两个 TabScript
我在一个页面用了TabScript 为什么只有第一个起作用
一个页面能不能有两个 TabScript
我在一个页面用了TabScript 为什么只有第一个起作用
解决方案 »
- 求助 奇怪的问题 为什么一个站点不同的目录请求会出现301
- 如何将对象转换成字节数组???
- Fileupload 上传大文件获得文件名问题
- 如何判断指定路径的文件夹是否存在,如果不存在就自动创建一个文件夹???
- 有个问题
- *****************我的存储过程在Delphi中为何报错*********************
- 如何解决美国网站的中文乱码的问题?
- 如何通过网络打开服务器端的excel文件..
- Application问题,急,急,急!!!
- 当页面在请求其它AJAX时,会导致setInterval倒计时不准,深入了解过setInterval和setTimeout进来回复下
- 屏蔽所有特殊符号的验证表达式该怎么写?比如"!@#$%^&*()_+|':;<>,.?/-/\"
- 登陆时,如果想要一周内不用登陆代码怎样写
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title></title>
<meta name="GENERATOR" content="Microsoft Visual Studio .NET 7.1">
<meta name="vs_targetSchema"content="http://schemas.microsoft.com/intellisense/i">
<STYLE type="text/css">
.conts {visibility:hidden}
.tab {border-top:solid thin #E0E0E0;
border-right:solid thin gray;
border-left:solid thin #E0E0E0;
font-family:Verdana;
font-size:10pt;
text-align:center;
font-weight:normal} .selTab {border-left:solid thin white;
border-top:solid thin white;
border-right:solid thin black;
font-weight:bold;
text-align:center}
</STYLE>
<SCRIPT LANGUAGE="JavaScript">
//a public function that the container uses to pass in values for the labels
function public_Labels(label1, label2, label3, label4, label5, label6, label7)
{
t1.innerText = label1;
t2.innerText = label2;
t3.innerText = label3;
t4.innerText = label4;
t5.innerText = label5;
t6.innerText = label6;
t7.innerText = label7;
} //a public function that the container uses to pass in values for the card containers
function public_Contents(contents1, contents2, contents3, contents4, contents5, contents6, contents7)
{
t1Contents.innerHTML = contents1;
t2Contents.innerHTML = contents2;
t3Contents.innerHTML = contents3;
t4Contents.innerHTML = contents4;
t5Contents.innerHTML = contents5;
t6Contents.innerHTML = contents6;
t7Contents.innerHTML = contents7;
init();
} //sets the default display to tab 1
function init()
{
tabContents.innerHTML = t1Contents.innerHTML;
} //this is the tab switching function
var currentTab;
var tabBase;
var firstFlag = true;
function changeTabs()
{
if(firstFlag == true)
{
currentTab = t1;
tabBase = t1base;
firstFlag = false;
} if(window.event.srcElement.className == "tab")
{
currentTab.className = "tab"; tabBase.style.backgroundColor = "white"; currentTab = window.event.srcElement; tabBaseID = currentTab.id + "base"; tabContentID = currentTab.id + "Contents"; tabBase = document.all(tabBaseID); tabContent = document.all(tabContentID); currentTab.className = "selTab";
tabBase.style.backgroundColor = ""; tabContents.innerHTML = tabContent.innerHTML;
}
}
</SCRIPT>
</head>
<body bgcolor="#fef4d9" onload=init() onclick=changeTabs()>
<DIV STYLE="position:absolute; top:40; height:350; width:500; left:25; border:none thin gray">
<TABLE STYLE="width:100%; height:250" CELLPADDING="0" CELLSPACING="0" ID="Table1">
<TR>
<TD ID="t1" CLASS="selTab" HEIGHT="25">tab 1</TD>
<TD ID="t2" CLASS="tab">tab 2</TD>
<TD ID="t3" CLASS="tab">tab 3</TD>
<TD ID="t4" CLASS="tab">tab 4</TD>
<TD ID="t5" CLASS="tab">tab 5</TD>
<TD ID="t6" CLASS="tab">tab 6</TD>
<TD ID="t7" CLASS="tab">tab 7</TD>
</TR>
<TR>
<TD ID="t1base" STYLE="height:2; border-left:solid thin white"></TD>
<TD ID="t2base" STYLE="height:2; background-color:white"></TD>
<TD ID="t3base" STYLE="height:2; background-color:white"></TD>
<TD ID="t4base" STYLE="height:2; background-color:white"></TD>
<TD ID="t5base" STYLE="height:2; background-color:white"></TD>
<TD ID="t6base" STYLE="height:2; background-color:white"></TD>
<TD ID="t7base" STYLE="height:2; background-color:white; border-right:solid thin white"></TD>
</TR>
<TR>
<TD HEIGHT="*" COLSPAN="7" ID="tabContents" STYLE=" border-left:solid thin white;
border-bottom:solid thin white;
border-right:solid thin white">sample contents</TD>
</TR>
</TABLE>
</DIV>
<DIV CLASS="conts" ID="t1Contents">This text is on tab one</DIV>
<DIV CLASS="conts" ID="t2Contents">This text is on tab two</DIV>
<DIV CLASS="conts" ID="t3Contents">This text is on tab three</DIV>
<DIV CLASS="conts" ID="t4Contents">This text is on tab four</DIV>
<DIV CLASS="conts" ID="t5Contents">This text is on tab five</DIV>
<DIV CLASS="conts" ID="t6Contents">This text is on tab six</DIV>
<DIV CLASS="conts" ID="t7Contents">This text is on tab seven</DIV>
</body>
</html>
直接拷贝到html文件中