- 博客(10)
- 收藏
- 关注
原创 IDEA 乱码问题解决
3、IDEA.exe bin 目录下 idea64.exe.vmoptions 文件下添加 -Dfile.encoding=UTF-8。4、idea help edit custom VM options 末尾行同样添加 -Dfile.encoding=UTF-8。6、tomcat 文件夹下 con/logging.properties 修改为 utf-8。2、Tomcat - Edit 添加 -Dfile.encoding=UTF-8。7、项目中请求 http get或者post请求返回乱码。
2023-11-20 10:27:26
132
原创 数据库中数据类型为longblob的文件,byte[]文件下载功能(到指定文件目录),HTML及java示例
文件下载、指定文件夹、byte[]、指定文件
2023-08-03 15:27:44
295
原创 JAVA后端获取请求用户IP,根据IP查询当地实时天气
try{ String ip = getIpAddress(request); String result = ZcgGetPosttUtils.doGet("http://apis.map.qq.com/ws/location/v1/ip?key=5Q5BZ-5EVWJ-SN5F3-K6QBZ-B3FAO-RVBWM&ip=" + ip); String cityName = "哈尔冰"; JSONObject jsonObjectResult = new JSO.
2021-08-05 17:25:25
496
原创 notepad++ 突然自动关闭
只要是以文本文件打开的文件,不管是以文本文件打开,还是用 notepad++ 打开,突然间就退出去了,搞得一脸闷,最后尝试发现,在文件中输入 socket 或者 #socket 都会自动退出去,文件也做不到保存。在这里我们也可以想退出文件编辑状态的时候,先保存一下文件,然后输入 socket ,文件就自动关闭了,内容也做到了保存...
2021-07-15 10:29:14
1264
原创 HttpClient POST 请求 form data java示例
long start = System.currentTimeMillis(); int count = 0; File file = new File("C:\\xxx.txt"); if (file.isFile() && file.exists()) { try { String url = "http://bs.crrcgc.cc/crrc-bs2/idisProxy/analyzeIdentification"...
2021-06-11 09:55:30
914
1
原创 PDF 文件添加图片水印,并去除 Evaluation Warning : The document was created with Spire.PDF for...
1、IDEA 导包com.e-icebluehttp://repo.e-iceblue.cn/repository/maven-public/e-icebluespire.pdf3.4.2拉去 jar 包 --> import Changes2、代码实现import com.spire.pdf.PdfDocument;import com.spire.pdf.PdfPageBase;import com.spire.pdf.annotations.PdfRubberStampAn
2020-07-03 17:09:17
3354
原创 java httpclient get 和 post 请求方式 application/x-www-form-urlencoded post方式
httpclient post get 请求后台接口import org.apache.http.HttpEntity;import org.apache.http.HttpResponse;import org.apache.http.HttpStatus;import org.apache.http.StatusLine;import org.apache.http.client.HttpClient;import org.apache.http.client.methods.Closeab
2020-07-02 11:12:42
3977
原创 java.io.IOException: Connection reset by peer问题解决
java.io.IOException: Connection reset by peer完整错误信息c.c.s.listener.DefaultExceptionListener : Connection reset by peerjava.io.IOException: Connection reset by peerat sun.nio.ch.FileDispatcherImpl.read0(Native Method) ~[na:1.8.0_171]at sun.nio.ch.Socke
2020-05-11 16:07:02
4270
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人