$(document).ready(function () { $.ajax({ type: "GET", url: "https://mysafeinfo.com/api/data?list=presidents&format=xml&rows=5&sort=id desc&case=lower", dataType: "xml", success: function (result) { $(result).find("p").each(function () { $("#presidents").append($("<option />").val($(this).attr("id")).text($(this).attr("fullname"))); }); } }); });
<select id="presidents"></select>