-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
在jsp页面可以直接使用application对象, 在servlet中却不能直接使用,
这如何是好呢?在servlet 中使用application方法如下:
this.getServletContext().setAttribute("user","123456");
--------------------------------------------------------------------------------------------
注:在servlet中
this.getServletContext()返回的就是application对象