私は映画API(https://www.themoviedb.org/documentation/api)を使用していますが、apiはページあたり20個の結果しか得られません.60件を取得したいので、3ページで3回リクエストします。 私は私がJSONエンコードを使用するか、応答をデコードする必要がある場合は知らないが、これは最初の結果リストの作品:私は「結果」への第二と第三の要求の結果を置く方法を知らないPHP Angularjs JSON複数のAPIレスポンス
$url1 = "http://api.themoviedb.org/3/movie/upcoming?api_key=###&page=1&language=de";
$url2 = "http://api.themoviedb.org/3/movie/upcoming?api_key=###&page=2&language=de";
$url3 = "http://api.themoviedb.org/3/movie/upcoming?api_key=###&page=3&language=de";
$response1 = file_get_contents($url1);
$response2 = file_get_contents($url2);
$response3 = file_get_contents($url3);
echo $response1;
: APIのブラウザで
角部
a.filme = []; //declare an empty array
$http({
method: 'GET',
url: 'data/call-api.php'
}).then(function (response){
a.filme = response.data.results;
console.log(response.data);
},function (error){
console.log("JSON konnte nicht geladen werden: " + error.status + error.statusText);
});
REPONSE(http://api.themoviedb.org/3/movie/upcoming?api_key=###&page=1&language=de)次のようになります。事前に
感謝:)