Assistance de TMDB

It seems many background images (if not all) have no ISO country code, so when attempting to access image info using the include_image_language parameter the background images are not listed. Here is an example:

Example collection

http://api.themoviedb.org/3/collection/115570?api_key=xxx&append_to_response=images
This url lists all the background images

http://api.themoviedb.org/3/collection/115570?api_key=xxx&append_to_response=images&language=en&include_image_language=??
Once a language is specified there is no way to list the background images without an ISO specified country. What should be used here? We have tried null but it needs to be a valid ISO code per the API docs.

7 réponses (sur la page 1 sur 1)

Jump to last post

Hi Tim,

The documentation mentions that null is valid option for include_image_language. I'm not entirely sure I understand the issue. Here's the example straight from the docs:

https://api.themoviedb.org/3/movie/550/images?api_key=###&language=en&include_image_language=en,null

Did you read the "Image Languages" section? Does that cover it?

I missed that in the docs, but we do pass in null, yet in this instance (and many others ) no background images are listed at all.

http://api.themoviedb.org/3/collection/115570?api_key=xxx&append_to_response=images&language=en&include_image_language=en,null

Results:
..."images":{"backdrops":[],...

EDIT Trying the example URL works, so it must be some difference in the collections versus movies API.

Hey Tim,

If I request this method here:

http://api.themoviedb.org/3/collection/115570?api_key=###&append_to_response=images&include_image_language=en,null

I am getting back:

{
  "id": 115570,
  "name": "Star Trek: The Next Generation Collection",
  "overview": "Star Trek: The Next Generation Motion Picture Collection contains the four Next Generation films.",
  "poster_path": "/5HOcAfSfFxmpUouyLOo6Si9F7fo.jpg",
  "backdrop_path": "/r7MMQenUURHhAVHFymtOb8AX4Bm.jpg",
  "parts": [ ... ],
  "images": {
    "backdrops": [
      {
        "aspect_ratio": 1.78,
        "file_path": "/r7MMQenUURHhAVHFymtOb8AX4Bm.jpg",
        "height": 1080,
        "iso_639_1": "xx",
        "vote_average": "5.39915966386555",
        "vote_count": 5,
        "width": 1920
      },
      {
        "aspect_ratio": 1.78,
        "file_path": "/y6IWUJkDWbPiLOuc23jbLotRPIu.jpg",
        "height": 1080,
        "iso_639_1": null,
        "vote_average": "5.26041666666667",
        "vote_count": 1,
        "width": 1920
      },
      {
        "aspect_ratio": 1.78,
        "file_path": "/xb6wgQzRLWoZSDk06esOMc9PbwU.jpg",
        "height": 1080,
        "iso_639_1": null,
        "vote_average": "5.26041666666667",
        "vote_count": 1,
        "width": 1920
      }
    ],
    "posters": [ ... ]
  }
}

Include &language=en and then it doesn't work.

I am new to the project and the API, but I believe the idea is to get the description for the specified locale, but when that is specified then the background images do not display even when null is included.

Ah yes, I missed that param in my example.

I've created a new ticket for that here. I'll try to it fixed up in the next day or two.

Cheers.

The fix for this should be live. Mind giving it a go now?

Yep. Works as expected now:

"images":{"backdrops":[{"aspect_ratio":1.78,"file_path":"/r7MMQenUURHhAVHFymtOb8AX4Bm.jpg","height":1080,"iso_639_1":"xx", "vote_average":"5.39915966386555","vote_count":5,"width":1920},{"aspect_ratio":1.78,"file_path":"/y6IWUJkDWbPiLOuc23jbLotRPIu.jpg","height":1080,"iso_639_1":null, "vote_average":"5.26041666666667","vote_count":1,"width":1920},{"aspect_ratio":1.78,"file_path":"/xb6wgQzRLWoZSDk06esOMc9PbwU.jpg","height":1080,"iso_639_1":null, "vote_average":"5.26041666666667","vote_count":1,"width":1920}]

Un film, une émission télévisée ou un artiste est introuvable ? Connectez-vous afin de créer une nouvelle fiche.

Général

s Mettre le curseur dans la barre de recherche
p Ouvrir le menu du profil
esc Fermer une fenêtre ouverte
? Ouvrir la fenêtre des raccourcis clavier

Sur les pages des médias

b Retour (ou vers le parent si faisable)
e Afficher la page de modification

Sur les pages des saisons des émissions télévisées

Afficher la saison suivante (flèche droite)
Afficher la saison précédente (flèche gauche)

Sur les pages des épisodes des émissions télévisées

Afficher l'épisode suivant (flèche droite)
Afficher l'épisode précédent (flèche gauche)

Sur toutes les pages des images / photos

a Ouvrir la fenêtre d'ajout d'image / photo

Sur toutes les pages de modifications

t Ouvrir le sélecteur de traduction
ctrl+ s Envoyer le formulaire

Sur les pages des discussions

n Créer une nouvelle discussion
w Basculer le statut de suivi
p Basculer publique / privée
c Basculer fermer / ouvrir
a Ouvrir l'activité
r Répondre à la discussion
l Afficher la dernière réponse
ctrl+ enter Envoyer votre message
Page suivante (flèche droite)
Page précédente (flèche gauche)

Paramètres

Vous souhaitez évaluer ou ajouter cet élément à une liste ?

Connexion