PHP CURL错误 - curl:(56)Recv故障:由对等体重置连接 [英] PHP CURL Error - curl: (56) Recv failure: Connection reset by peer

查看:2722
本文介绍了PHP CURL错误 - curl:(56)Recv故障:由对等体重置连接的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

基本上,此错误只发生在CURL

basically, this error only occurs in CURL

curl: (56) Recv failure: Connection reset by peer

但是当我直接在浏览器上访问链接时,它可以正常工作!

But when I visit it directly the link directly on my browser, it works!

您对修正此错误或造成此错误的原因有何建议?

What are your recommendations on fixing this one or the cause of this error?

注意:服务器编码为ASP,一个API调用

Note: the server is coded in ASP and it only occurs on one API Call

推荐答案

我记得面对这个问题很长时间了。虽然我不记得究竟排序的问题,但我记得尝试以下:

I remember facing this issue a long time back. While I don't remember what exactly sorted the issue, but I remember trying the following:

1)我试图直接传递查询参数的url和我尝试通过POST方法

1) I was trying to pass the query parameters in the url directly and I tried passing through POST method

2)我尝试使用curl代理查看是否可能被其他服务器阻止

2) I tried using a proxy with curl to see if I was possibly being blocked by the other server

3)我相信我也要求我的主机调查它们,并做了一些Apache设置更改

3) I believe I also asked my host to look into it and they made some Apache setting changes

这篇关于PHP CURL错误 - curl:(56)Recv故障:由对等体重置连接的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆