In #Al_2(SO_4)_3#, the subscript of three next to the #SO_4# polyatomic ion refers to the number of that same ion is in this molecule. Since there are four atoms of oxygen in each #SO_4#, indicated by the subscript of four next to the oxygen, and there are three #SO_4# ions, #4*3= 12# oxygen atoms present in #Al_2(SO_4)_3#.