I’m not sure if I’m looping through the json data correctly. Could someone tell me what I’m doing incorrectly? https://codepen.io/lalov1/pen/EyXyOz
You’re iterating the wrong thing. Try this code out and see how it’s different:
success: function(data){
//console.log(data.query.search["0"].snippet);
console.log(data.query.search)
}
Awesome! That worked, but I don’t see how I would get the specific page. How does that work?
Thank you!
Do you mean the link to the Wikipedia article? They are all https://en.wikipedia.org/wiki/ + articleTitle
so you can generate them easily.
Yes, I’ll give it a try!