zoukankan      html  css  js  c++  java
  • 服务器返回 HTTP 500

    把自己伪装成浏览器

    Some servers (especially requested with SSL) returns 500 in cases when some parameters of request is set incorrect.

    To avoid «500 error» (for example) be sure to:

    • set proper "Referer: " header if needed, with

    curl_setopt(CURLOPT_REFERER, 'http://site.com/ref_page');

    • set proper "User-Agent: " header, with

    curl_setopt(CURLOPT_USERAGENT, 'Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0)');

    by Macik

    https://stackoverflow.com/questions/2453207/curl-http-post-keep-getting-500-error-has-no-idea

  • 相关阅读:
    Activity
    日志
    StringBuffer
    内部类
    接口
    多态
    final关键字
    abstract关键字
    对象初始化
    继承
  • 原文地址:https://www.cnblogs.com/liujx2019/p/13453293.html
Copyright © 2011-2022 走看看