(1)是说jsp开发中经常遇到的异常是由于变量未经初始化就使用而造成的空指针异常,在变量声明的同时就初始化它可以有效避免这类问题(这是谁写的?绝对了点)
(2)告诉你由于服务端应用异常而导致错误,返回状态码500
(3)告诉你具体的出错位置
(4)告诉你这个错误就是(1)

解决方案 »

  1.   

    1、空指针主要是因为逻辑不严谨造成的。坚持在使用对象以前,先判断就可以避免,例如:
    String s = (String)session.getAttribute("test");//判断
    if(s != null){
      //你的逻辑
    }2、500这样的数字叫做状态码,是HTTP协议中对于特定情况的编码,如404代表请求的页面不存在这种情况。
      

  2.   

    3、这些都是系统类库中的类的出错位置,没有太多的帮助。4、说明空指针异常出现在yxs_jsp.java的79行。
    yxs_jsp.java是yxs.jsp编译生成的Servlet源代码,可以在Tomcat安装目录下的work目录中找到。
      

  3.   

    some HTTP status codes:     status code       Status Message           Description
     
        200               OK                       Request was handled without error  
        301               Moved permanently        Content has moved to  hostname  in the Location header
        400               Bad request              request could not be understood by the server
        403               Forbidden                Server lacks permission to access the requested file 
        404               Not found                Server could not find the requested file
        501               Not implemented          Server does not support the request method
        505               HTTP version not supported     Server does not support version in request