I am just making a basic ajax call to 'http://api.themoviedb.org/3/genre/movie/list&api_key=#####' I keep getting a 'Cannot get' error? what am I doing wrong?
Non riesci a trovare un film o una serie Tv? Accedi per crearlo.
Vuoi valutare o aggiungere quest'elemento a una lista?
Non sei un membro?
Risposta da Travis Bell
il 13 agosto, 2016 alle 11:38AM
Hi Luke,
I'm not sure. Everything looks fine to me. How are you making the request?
Risposta da luke_simmon
il 13 agosto, 2016 alle 2:14PM
Here it is:
Risposta da Travis Bell
il 14 agosto, 2016 alle 11:15AM
Even though you have your dataType set to jsonp, is is sending along a callback?
This test of mine here is working fine (make sure to replace your API key on line 11).
Risposta da luke_simmon
il 14 agosto, 2016 alle 11:47AM
I am using the api in many other instances, genre has been the only on genre. I see that you added a query at the end, is that necessary? I am trying to get the list of genres to use for the movies gennre codes that I get.
Risposta da Travis Bell
il 14 agosto, 2016 alle 1:55PM
No, it is not necessary. It was accidentally left from a previous example.
Risposta da luke_simmon
il 14 agosto, 2016 alle 6:53PM
Cannot GET https://api.themoviedb.org/3/genre/movie/list&api_key=####?callback=jQuery22408132628371243029_1471207855881&_=1471207855884
Risposta da Travis Bell
il 15 agosto, 2016 alle 12:22AM
That's not a valid HTTP request. You're looking for:
Risposta da luke_simmon
il 15 agosto, 2016 alle 4:08PM
forgive me. I am not seeing a difference between your request and my request
Risposta da Travis Bell
il 15 agosto, 2016 alle 7:26PM
You're starting your query string with an ampersand. That's not valid HTTP, so it's ignoring your API key param and only reading from the question mark and on. In my example, I fixed that for you.
Risposta da luke_simmon
il 16 agosto, 2016 alle 1:39PM
thanks for your help. that fixed it