java,eclipse中如何添加httpclient.jar

  1、Download 'Binary' package of the latest official release from the project download page.

There should be 7 jars in total (components marked with (*) include additional features and are optional) on the classpath.

  • commons-logging-x.x.x.jar
  • commons-codec-x.x.x.jar
  • httpcore-x.x.x.jar
  • httpclient-x.x.x.jar
  • httpmime-x.x.x.jar (*)
  • httpclient-cache-x.x.x.jar (*)
  • fluent-hc-x.x.x.jar (*)
    2、把这几个.jar文件放到  Javajdk1.7.0_17jrelibext目录下面,不同的安装版本可能有差异。

    3、引用,右键点击工程名->bulid paths->add external Archives->选择刚才添加的.jar文件即可。
原文地址:https://www.cnblogs.com/nannanITeye/p/3302528.html