My question is asked before for using javascript variables with the Single jQuery selector, As in this post below.
How to use javascript variables in jquery selectors
But my question is how to use one variable with two or more selectors?
var itemId = $(this).closest('li').attr('id');
This is for one selector
var contentType = $('#' + itemId + ' .content-type');
But how to use itemId
when i have two selectors in one row like below
var contentType = $('.content-type1, .content-type2');