javascript - js append div to only current parents child -
i have div block repeated on page each product. using js cycle through instances of div class , move div div in same block. wrote this:
$(value).appendto('.product-image') and adds each div product-image divs on page. how can add each div product-image div child of $(values) parent?
this did not work me:
$(value).appendto($(value).parent().find('.product-image'))
try select first parent div. $(value).appendto($(value).parent('div:first()').find('.product-image'))
Comments
Post a Comment