$.getJSON('data.json', function(data){ vals = data.mob.split(","); var $jsontwo = $(subcategory); $jsontwo.empty(); $.each(vals, function(index, value) { $jsontwo.append("<option>" + value + "</option>"); }); });