I have inputs that change image. one of them adds default border 10px solid black
and other input (radio) should give a shadow to an image (it's border-bottom+border-right) I want to use them both at one time but I cannot. How can I do that?
<script>
function ramka_size(){
var input = document.getElementById('name').value;
let ramka = document.getElementsByClassName('woocommerce-product-gallery__image');
for(var i=0; i<ramka.length; i++){
ramka[i].style.border= input+'px solid black';
}
}
function canvas(){
var input = document.getElementById('name').value;
let border = document.getElementsByClassName('woocommerce-product-gallery__image');
for(var i=0; i<border.length; i++){
border[i].style.borderBottom= '10px solid grey';
border[i].style.borderRight= '10px solid grey';
}
}
jQuery(document).ready(function($) {
$('.woocommerce-product-details__short-description').after( \"<input type='number' class='form-control' name='name' id='name' onchange='ramka_size()' value='' placeholder='Размер рамки'> <br> <br> <div> <input type='radio' onclick='canvas()' name='CanvasOrPaper' class='form-control' id='contactChoice1'value = 'canvas'><label for='contactChoice1'>Холст</label> <br> <input type='radio' onclick='paper()' name='CanvasOrPaper' class='form-control' id='contactChoice2' value = 'paper'><label for='contactChoice2'>Бумага</label> </div>\" );
});
</script>