Deezer API: Search result is empty

荒凉一梦 提交于 2019-12-20 05:19:17

问题


I've got a problem. I'm making something with the Deezer api. When I try to search with the api I'm always getting an empty result.

To test it I'm using this code:

<?php
echo file_get_contents('https://api.deezer.com/2.0/search?q=Avicii');
?>

When I visit the url in my browser it works fine. But when I visit the PHP-file it outputs:

{"data":[],"total":0}

I'm also getting data from a Deezer playlist and that works fine! I searched the web for it but I've got no idea what's wrong.

Thanks in advance!

来源:https://stackoverflow.com/questions/20657929/deezer-api-search-result-is-empty

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!