我想将数据从桌面传递给servlet。我已经尝试了一种方法,当iItry传递给servlet时,我能够获取数据我无法从compile group: 'org.apache.httpcomponents' , name: 'httpclient-android' , version: '4.3.5'
获取null的数据。请告诉我的代码中有什么错误
ArrayToJson
request.getParameter("forecastdata");
的JavaScript
@WebServlet("/arrayToJson/*")
public class ArrayToJson extends HttpServlet {
@Override
protected void doPost(final HttpServletRequest request,
final HttpServletResponse response) throws ServletException,
IOException {
StringBuffer jb = new StringBuffer();
String line = null;
request.getParameter("forecastdata");
;
}
}
答案 0 :(得分:0)