The thing is that I wanted to click on a "button" (I put it in quotes because it's just a button in appearance) different options are displayed.
This I do with the animation of Jquery
.fadeToggle()
Why is only the first option displayed to me? How do I show them all? (In this case they are all 2).
Code:
$(document).ready(function() {
$('#Btn-Selector-Rutina').click(function() {
$('#Btn-Subselector-Rutina').fadeToggle();
});
});
.Btn-Selector {
height: auto;
width: 200px;
padding: 5px;
text-align: center;
margin: auto;
border: solid 2px;
border-color: #21211d;
cursor: pointer;
}
#Btn-Subselector-Rutina {
display: none;
border-top-style: none;
}
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<div id="Selector-Rutina">
<p class="Btn-Selector" id="Btn-Selector-Rutina">Tipo de rutina</p>
<p class="Btn-Selector" id="Btn-Subselector-Rutina">Rutina 1</p>
<p class="Btn-Selector" id="Btn-Subselector-Rutina">Rutina 2</p>
</div>