【发布时间】:2020-03-06 04:13:25
【问题描述】:
我创建了一个 JSP、Servlet 和 Java 页面,但现在尝试获取 MyAlgorithm(Java 算法)的输出并将其发送回我的 JSP 页面。但是它不起作用...我在这里遗漏了什么吗?
如果问题不清楚,请询问我。
protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
// TODO Auto-generated method stub
response.getWriter().append("Served at: ").append(request.getContextPath());
}
/**
* @see HttpServlet#doPost(HttpServletRequest request, HttpServletResponse response)
*/
protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
// TODO Auto-generated method stub
String s_LocalDate = request.getParameter("s_JavascriptDate");
System.out.println(s_LocalDate);
algorithm MyAlgorithm = new algorithm();
MyAlgorithm.Days();
doGet(request, response);
}
【问题讨论】:
标签: javascript java jsp servlets