An Unexpected HTTP Error occurred during the API r

时间:10-04-12 栏目:网络&技术 作者:wukong 评论:0 点击: 1,111 次

An Unexpected HTTP Error occurred during the API r

查找插件的 时候报错

When I was logged into WP (2.8.4) and I tried to install a new plugin (from the dashboard), I would get the following error:

“An Unexpected HTTP Error occured during the API request.”

Basically, according to WP user efree_unix,

The cause of error is too long in the process of requesting the API plugin in the wordpress server so that the operation timed out. By default, wordpress give 5 seconds time limit to request a plugin. If within 5 seconds does not get a replay, then the process will be stopped and displayed an error “An Unexpected HTTP error occurred during the API request.”

THE SOLUTION:

Open wp_include/http.php file on line 223

‘timeout’ => apply_filters( ‘http_request_timeout’, 5),

change the script above into

‘timeout’ => apply_filters( ‘http_request_timeout’, 30),

That’s it, refresh and be merry!

声明: 本文由( wukong )原创编译,转载请保留链接: An Unexpected HTTP Error occurred during the API r

An Unexpected HTTP Error occurred during the API r:等您坐沙发呢!

发表评论

您必须 [ 登录 ] 才能发表留言!

------====== 本站公告 ======------
大家有任何疑问和建议,请到这里留言:点击留言板

读者排行