Closed RemyNovactive closed 3 years ago
Thank you for noticing that! I'll see what I can do about it as soon as I have some free time.
I, for one, did this to get around the problem...
public function autocomplete($keyword, $limit = 10) : Collection
{
$wikidata = new Wikidata();
$collection = $wikidata->search($keyword, 'fr', $limit);
return $collection->map(static function (SearchResult $item) {
$item->wikipedia_article = 'http://www.wikidata.org/entity/' . $item->id;
return $item;
});
}
composer.json :
"freearhey/wikidata": "^3.5",
(3.5.1)
Other than that, this bundle is great. Thanks :)
I have just published an updated version of the package, hopefully this will finally solve this problem.
In the search function, a piece of code create an url 'wikipedia_article'.
This url is the simple concatenation of the domain name and the label.
But the label does not contain the differentiation information between the different results. So, sometimes they all have the same URL...