# Random Quote machine - Help with getJSON

**URL:** <https://forum.freecodecamp.org/t/random-quote-machine-help-with-getjson/179415>\
**Category:** General\
**Created:** [March 13, 2018, 2:56am UTC](https://forum.freecodecamp.org/t/random-quote-machine-help-with-getjson/179415 "2018-03-13T02:56:26Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![DogHouseDaddy](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/doghousedaddy/32/81139_2.png) [@DogHouseDaddy](https://forum.freecodecamp.org/u/DogHouseDaddy)\
**Post date:** [March 13, 2018, 2:56am UTC](https://forum.freecodecamp.org/t/random-quote-machine-help-with-getjson/179415/1 "2018-03-13T02:56:26Z")

</div>

So I’ve been bashing my head into this for a couple days now, and I just can’t seem to make the getJSON function work. I’m certain that I’m missing something small and stupid, but I just don’t know enough to figure out what it is… It could very well be that the API I’m trying to call is wrong (though I’ve tried a few). If anyone could take a look at my codepen and give me some pointers, I would be grateful!

My pen is here:  
[https://codepen.io/DogHouseDaddy/pen/VXYojR](https://codepen.io/DogHouseDaddy/pen/VXYojR)

Thank you!

---

<div class="post-metadata">

**Author:** ![camperextraordinaire](https://avatars.discourse-cdn.com/v4/letter/c/5f9b8f/32.png) [@camperextraordinaire](https://forum.freecodecamp.org/u/camperextraordinaire)\
**Post date:** [March 13, 2018, 3:38am UTC](https://forum.freecodecamp.org/t/random-quote-machine-help-with-getjson/179415/2 "2018-03-13T03:38:05Z")

</div>

When ever your code does not work as you expect, always check the browser’s console (Ctrl+Shft+J in Chrome) to look for any error messages related to your code. If you do that, you will see an error message like:

> Uncaught ReferenceError: $ is not defined at pen.js:1

Instead of me just telling what to fix, can you tell me what the $ represents in your JavaScript?

---

<div class="post-metadata">

**Author:** ![DogHouseDaddy](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/doghousedaddy/32/81139_2.png) [@DogHouseDaddy](https://forum.freecodecamp.org/u/DogHouseDaddy)\
**Post date:** [March 13, 2018, 2:47pm UTC](https://forum.freecodecamp.org/t/random-quote-machine-help-with-getjson/179415/3 "2018-03-13T14:47:02Z")

</div>

> [@camperextraordinaire](#):
>
> When ever your code does not work as you expect, always check the browser’s console (Ctrl+Shft+J in Chrome) to look for any error messages related to your code.

Thank you! I was ignoring the console for some reason. Sometimes we have to have the obvious pointed out to us I guess. I loaded the jquery libraries and I’m now able to make the get request… Next is making the API work. Thanks again.

\*edit - I’ve finished this challenge now. You can check it out at the same link if you are interested. It’s bare bones, but the functionality is there. One last time, thanks for your help!

---

<div class="post-metadata">

**Author:** ![ILM](https://sea3.discourse-cdn.com/freecodecamp/user_avatar/forum.freecodecamp.org/ilm/32/363239_2.png) [@ILM](https://forum.freecodecamp.org/u/ILM)\
**Post date:** [January 17, 2021, 8:24pm UTC](https://forum.freecodecamp.org/t/random-quote-machine-help-with-getjson/179415/4 "2021-01-17T20:24:26Z")

</div>

Closed on January 17, 2021, 8:24pm UTC


