Help me with Wikipedia viewer

Help me with Wikipedia viewer
0

#1

I am stuck in json parsing,
please help me -

  • console is not showing json file

  • also font awesome is not showing up


#2

You are missing parens on line 17

$(document).ready(function(){

What is with the url on line 24?


#3

check it now please,i had pasted incomplete url before


#4

You are still missing parens (line 16) and you didn’t change the name of url on line 24.

You code corrected:

$(document).ready(function() {
  $(".btn").on("click", getRand);
  
  var formInput = $(".form-control").value;

  var apiurl = "https://en.wikipedia.org/w/api.php?action=query&titles=" + formInput + "&prop=revisions&rvprop=content&format=json&callback=?";
  
  $.getJSON(apiurl, function(data) {
    console.log(data);
  });
  /*$.getJSON(url,getResult);*/
});

#5

now i understood the parentheses and now feeling stupid,thanks,also font awesome is not loading


#6

Is loading for me:


#7

it was not loading in firefox but worked fine in chrome,tnks anyways