Hello I am currently using search api and I want to get the top five result from search query How I can get that result in search Api
Un film, une émission télévisée ou un artiste est introuvable ? Connectez-vous afin de créer une nouvelle fiche.
Vous souhaitez évaluer ou ajouter cet élément à une liste ?
Pas encore membre ?
Réponse de Travis Bell
le 3 octobre 2016 à 17h20
Hi Ahmed,
The search method returns a
results
field which is just an array. If you are only interested in seeing the top 5 results, you can just grab the first five items from the array. Most languages have an easy way of doing this, in Ruby it's as simple as:Hope that helps.