免责声明:我对 jQuery 和 JavaScript 比较陌生。只要确定#statementTab 尚未打开,就会执行下面的openStatement() 函数。如果下面的代码没有足够的信息,只需查看下面的源代码。
基本上,每当用户打开#statementTab 时,包含各种选项卡的 UL 都会闪烁并消失。我想解决这个问题。
资料来源: http: //www.cameronhermens.com/dbunkr/brochure.html
// The openStatement function opens the statement tab when the user clicks
<a id="openIt"> (if the statement tab isn't already open).
function openStatement() {
$('#explore').animate({width: '70%'}, '200');
$('#statementTab').animate({width: '213px'}, '1000');
};
// Here's the DIV.
<div id="explore" class="brochure">
<ul id="brochureTab">
<li><a href="welcome.html" >welcome</a></li>
<li><a href="ourMission.html">our mission</a></li>
<li><a href="whatIsdBunkr.html">what is dBunkr</a></li>
</ul>
</div>
<div id="statementTab">
<a id="openIt">
<img class="opaque left-5" src="images/rightArrow.jpg" height="10" width="6" alt="Expand the Statement tab">
<span class="statementBar">Statements</span>
</a>
</div>