Wikipedia Viewer help plzzzzzzzzzzzzzzz

I dont understand why my code is not working. When I try to search it doesn’t respond.
If some one can help me.
I have posted a link to my code pen down below.
Thank you
Also if any one has any tips,recommendations of videos etc on how to create an animation in js or css that would be much predicated.
Thank you


You’ve got a typo there.

Thnak you.
I have fixed it and still not responding.

You’ve got at least one more typo:

var searchTerm=$('#searchTerm').vsl();

There may be more, and you should be fishing them out. Open up your browser’s console and use your app. When you see red or yellow text in the console, it means there’s something wrong. Fix all the typos you can find and if you’re still having problems after that, come back here with another question.

for some odd reason my console is blank?
Any tips?

Your console may be filtering out warnings. Check the top of your console window for something like “Filter”. Here’s what it looks like in Firefox:


Right now, I’m not seeing any errors in the console, though.

thank you it works
now i have another issue where if i search for a word i get the error message.

This is the api call that I used, which worked:" + keyword + "&prop=info&inprop=url&utf8=&format=json. You should change keyword to searchterm to match your variable.

Thank you .
I used the api that you have provided but still when i use the Search bar and press search it gives me the error Message

This is the function that I call when the user clicks on the button:

function ajax (keyword) {
    url: "" + keyword + "&prop=info&inprop=url&utf8=&format=json",

   dataType: "jsonp",
   success: function(response) {
       if (response.query.searchinfo.totalhits === 0) {
       else {
   error: function () {
    alert("Error retrieving search results, please refresh the page");


I called this function in response to an element click:

      $("#searchButton").on("click", function () {

Like in @jonathn6’s example, setting the dataType to “jsonp” will correct your immediate problem. You should also remove async: false. It’s not doing you any favors and it’s automatically disabled when you use JSONP anyways.

thank you
I did all that but still no go.
What am i doning wrong ?

Open your console! Don’t rely on Codepen’s console because it doesn’t tell you much.


Take a look at the data that’s coming in and make sure you understand the format. You’re very close to being done!

it works
Thank you so much