我刚刚在我的项目中创建了两个php,其中一个php将使用fetch URL服务向另一个php发出post请求,它在我的本地开发服务器上运行良好,但当我将其部署在谷歌应用程序引擎上并返回HTTP/1.1 503 Service Unavailable时,它不起作用,UrlFetch每日配额不会超过。
这是我的代码
$postData = Array(
'myData' => 'value'
);
$context = [
'http' => [
'method' => 'POST',
'content' => http_build_query($postData)
]
];
$context = stream_context_create($context);
$result = file_get_contents('http://myapp.appspot.com/handler.php' , false, $context);
$serverResponse = json_decode($result, true);
$serverResponseHttpCode = $http_response_header[0];
echo $serverResponseHttpCode;
这是你的问题,所以不是真正寻求支持的地方,但我知道谷歌引用了Stackoverflow来获得支持。唯一的其他选择是购买白银或黄金支持,以便访问服务台。