var array1 = ["#div_id1", "#div_id2", "#div_id3"]; $(array1.join(',')).css({'width' : shirina , 'height' : vusota});