KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I'm trying to loop through this to get the 'name' values. This is what I currently have, but it doesn't seem to be working, tried a few others from what was posted here but nothing seemed to work. $.get("/get_names", {campaign_id: $('select[name="id"]').val()}, function(data){ $.each(data, function(i, item) { alert(item); }); } ); Json being returned: [ { "name":"age" }, { "name":"asdf" }, { "name":"drivername" }, { "name":"drivers" }, { "name":"firstname" }, { "name":"gender" }, { "name":"lastname" }, { "name":"make" }, { "name":"model" }, { "name":"vehicles" }, { "name":"year" } ] I've tried using: item.name item[i].name Any suggestions? Thank you!
Tags (comma-separated)
Save Edits
Cancel