我正在使用Foundation CSS並需要一些關於節對象的幫助。我在我的頁面上有一個標籤頁部分更改部分重點放在Foundation CSS中的按鈕單擊
<div class="section-container tabs" data-section="tabs">
<section id="section1">
<p class="title" data-section-title><a href="#">Step 1</a></p>
<div class="content" data-section-content>
<input type="text" id="firstname" placeholder="First Name">
</div>
</section>
<section id="section2">
<div class="content" data-section-content>
<input type="text" id="phone" placeholder="Phone">
</div>
</section>
What I am trying to do is have a next button on section1 that would take me to section 2 by using this
<button class="small button" id="next1" onclick="document.getElementById('section2').className ='active';document.getElementById('section1').style ='padding-top: 49px';document.getElementById('section1').className ='';document.getElementById('section1').style ='';"> Next </button>
但是這不起作用。會發生什麼是,通過點擊按鈕,我會在第2部分簡要介紹部分,然後回到第1部分。
不完整的代碼一起工作的成功。如何生根粉CSS? –
一些CSS會很棒 – Muath