Проблема с php и file_get_contents, allow_url_fopen - PullRequest
0 голосов
/ 08 октября 2018

У меня есть этот код

<?php
$string = file_get_contents("http://www.json-generator.com/api/json/get/bOSAcpFJwy?indent=2");
$json_a=json_decode($string,true);
$tama_array=sizeof($json_a);
print $tama_array;
?>

Я компилирую на своем компьютере, но не работает.У меня есть allow_url_fopen = On.Поэтому я не знаю, почему не работает

Это ошибка:

Предупреждение: file_get_contents (http://www.json -generator.com / api / json / get / bOSAcpFJwy? Indent = 2 ): в D: \ repositorio \ json \ koha-banner \ pruebajson.php в строке 2 0

...