2016-03-08 55 views
0

我已經成功使用HTML製作下拉菜單。問題是我不知道如何從下拉菜單移動到頁面。這是我的一段代碼:從HTML中的下拉菜單訪問選項卡

<div class="dropdown"> 
        <a href="#class="dropbtn"> Events</a> 
          <div class="dropdown-content"> 
            <a href="#"> Event1 </a> 
            <a href="#"> Event2 </a> 
            <a href="#"> Event3 </a> 
          </div> 
</div> 

我試過在div內使用id但它不工作。

+0
+0

' Events添加一個鏈接,而不是#'有報價失蹤,可能想要編輯 – tomiy

回答

0
Try Like this: 

<div class="dropdown"> 
        <a href="#class="dropbtn"> Events</a> 
          <div class="dropdown-content"> 
            <a href="https://www.google.co.in/"> Event1 </a> 
            <a href="https://in.yahoo.com/ 
"> Event2 </a> 
            <a href="http://www.rediff.com/"> Event3 </a> 
          </div> 
</div>