Styling issue with list items (from wiki API project)

So I got the hard part of the wikipedia API project out of the way, but just having some styling issues in my search results.

When you search something, sometimes the search heading and the search text description are not formatted properly.

The picture shows what I’m describing.

Here’s a link to my codepen:

Any help greatly appreciated!

this in your html Line 15

<ul class="list-group" id="output">

needs to be formatted correctly in your Js Line 20

$("#output").prepend("<li class='list-group-item'><a href="+data[3][i]+">"+data[1][i]+"</a><p>"+data[2][i]+"</p></li>");

Am I missing something? That’s the same code that I already have !

I know that’s your code - I’m not fixing it for you silly … I pointed out that YOU need to format your javscript html tags to what layout YOU want … :wink:

Ah I thought my eyes were going crazy for a sec haha.

Well I want it to lay out like

<ul class="list-group">
  <li class="list-group-item"><a href="#">Search title</a><p>Search Description</p></li>

Is this the wrong format?