通常は「お問い合わせ」と表示される下部バーを作成したいのですが、バーをクリックすると連絡先の詳細が表示され、もう一度クリックするとバーが「お問い合わせ」と表示されます。私は toggle() を試しましたが、その後、Contacts us + と詳細の両方が隠されている状況に陥りました。
else ステートメントが必要だと思いますが、jQuery に関する知識が不足しています。
http://jsfiddle.net/DzYTZ/2/ (何らかの理由で動作していません)
誰でも助けてもらえますか?
ありがとう
<div class="footer2">
<a href="#" class="contactus">
Contact Us
</a>
<div class="more">
<a href="#">
@twitterhandle
</a>
<a href="#">
e-mail
</a>
</div>
</div>
.footer2
{
background-color: black;
margin-top: 1em;
padding-top: 1em;
padding-bottom: 1em;
text-align: center;
width: 100%;
}
.footer2 .contactus
{
font-family: 'Open Sans', sans-serif;
font-weight: 400;
color: #e3e3e3;
text-decoration: none;
display: inline;
}
.footer2 .contactus:hover
{
color: white;
}
.footer2 .more
{
margin-left: 1em;
display: none;
font-family: 'Open Sans', sans-serif;
font-weight: 400;
display: inline;
}
.footer2 .more a
{
margin-left: 2em;
color: #e3e3e3;
text-decoration: none;
}
.footer2 .more a:hover
{
color: white;
}