The Movie Database サポート

Hi, Iam new here and i was wondering if the API is always so slow or if i had made a mistake. I have written a little php script with 10 movieID`s which loads the Covers of the Movies and it takes about 10 sek. to load... is this normal or am i doing something wrong? Here is my Script:

<?php
$api = "MyKey";
$url = "https://api.themoviedb.org/3/";
$Filme = ['27205','242582','1124','68718','77','600','49047','680','273248'];
$x = 0;
while($x < count($Filme)){
    $json = file_get_contents($url."movie/".$Filme[$x]."?api_key=".$api."&language=de");
    $daten = json_decode($json, TRUE);
    echo "";
    $x++;
    }
?>

I tried it on my local machine and on my web server in Frankfurt-Germany Thanks in advance

1 reply (on page 1 of 1)

Jump to last post

Hi @JürgenTrings,

I would say that it is certainly not normal but I can't really help you without having you separate the requests. api.themoviedb.org and image.tmdb.org are on completely different networks. If you can run through the ids and not grab images, it should help you understand which one is being slow.

Another thing to mention is to make sure you're using a persistent HTTP connection. I ran through some examples of the difference this makes with another user here if you're interested.

Cheers.

映画やテレビ番組が見つかりませんか?ログインして作成してください。

全般

s 検索バーに移動する
p プロファイルメニューを開く
esc 開いているウィンドウを閉じる
? キーボードショートカットウィンドウを開く

メディアのページ

b 戻る(または該当する場合は親に)
e 編集ページに行く

テレビ番組のシーズンのページ

(右矢印)次のシーズンに行く
(左矢印)前のシーズンに戻る

テレビ番組のエピソードのページ

(右矢印)次のエピソードに進む
(左矢印)前のエピソードに戻る

全ての画像のページ

a 画像追加ウィンドウを開く

全ての編集ページ

t 翻訳選択を開く
ctrl+ s フォームを送信する

ディスカッションのページ

n 新しいディスカッションを作成する
w 監視ステータスを切り替える
p 公開/非公開を切り替える
c 閉じる/開くを切り替える
a アクティビティを開く
r ディスカッションに返信
l 最後の返事に行く
ctrl+ enter メッセージを送信する
(右矢印)次のページ
(左矢印)前のページ

設定

このアイテムを評価したり、リストに追加したりしたいですか?

ログイン

メンバーではありませんか?

登録してコミュニティに参加