Answer the question
In order to leave comments, you need to log in
How to output certain array data based on value value in JS?
There is a trace. task:
When you click on the button (radio), information about the product should be displayed.
For example, let it be a title, a product description and an image.
<div class="wrapper">
<!-- Панель кнопок -->
<div class="panel buttons">
<input class="button" name="tovar" type="radio" value="tovar1" id="but1">
<label for="but1">товар 1</label>
<input class="button" name="tovar" type="radio" value="tovar2" id="but2">
<label for="but2">товар 2</label>
<input class="button" name="tovar" type="radio" value="tovar3" id="but3">
<label for="but3">товар 3</label>
</div>
<!-- End Панель кнопок -->
<!-- Окно данных -->
<div class="data-window">
<div class="images"></div>
<div class="coontent">
<div class="title"></div>
<div class="text"></div>
</div>
</div>
<!-- End Окно данных -->
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question