0
我在div上使用了onclick切換功能。我會告訴他們的一個例子:在常見問題頁面上切換
<div id="question1">
<a href="#" style="color: #FFF"
onclick="toggle('answer1');">Can I access my work from home?</a>
</div>
<div style="display:none" id="answer1">
You can't access you University drive from home, it is advised to back up your work onto a cloud such as Google Drive or Dropbox. You can however access your tasks and see what deadlines you have to meet using something called Blackboard.
</div>
所以,當我點擊第一個問題的第一個答案表明,我只是想知道如何隱藏的,當我點擊問題2?所以最終不可能一次顯示2個答案。