我在这里使用 json 简单库编写 json 数据
现在代码运行良好,我能够得到输出。代码是 -
<%@page contentType="application/json" pageEncoding="UTF-8"
import="org.json.simple.JSONObject"%>
<%
JSONObject json = new JSONObject();
newa.NewClass1 newca = new newa.NewClass1();
try {
String s_id = session.getAttribute("id").toString();
json.put("count", newca.get_update_count(s_id) );
} catch (Exception e) { json.put("count", "0" ); }
out.println(json);
json.clear();
out.flush();
out.close();
%>
现在每次我点击页面时,我都会在服务器日志中收到警告 -
WARNING: Internal error flushing the buffer in release()
当我在代码中使用 out.flush 时,如何刷新缓冲区。
问候