2 Replies Latest reply on Jul 22, 2003 1:10 AM by jrmad2003

    Error deploying the war file

    uzair Newbie

      HTTP ERROR: 500 Unable to compile class for JSPNote: sun.tools.javac.Main has been deprecated. An error occurred between lines: 1 and 8 in the jsp file: /Jsp1.jsp Generated servlet error: C:\DOCUME~1\uzair\LOCALS~1\Temp\Jetty_0_0_0_0_8080__JSPHello\Jsp1$jsp.java:56: Missing term. out.write("\r\n\r\n\r\nJsp1\r\n\r\n\r\n\r\n"); ^ An error occurred at line: 8 in the jsp file: /Jsp1.jsp Generated servlet error: C:\DOCUME~1\uzair\LOCALS~1\Temp\Jetty_0_0_0_0_8080__JSPHello\Jsp1$jsp.java:63: Missing term. helloBean= (/Hello) ^ An error occurred at line: 8 in the jsp file: /Jsp1.jsp Generated servlet error: C:\DOCUME~1\uzair\LOCALS~1\Temp\Jetty_0_0_0_0_8080__JSPHello\Jsp1$jsp.java:68: Missing term. helloBean = (/Hello) java.beans.Beans.instantiate(this.getClass().getClassLoader(), "/Hello"); ^ 3 errors, 1 warning
      RequestURI=/JSPHello/Jsp1.jsp



      This is the error i am getting . AS soon as i try to use other class in my jsp

        • 1. Re: Error deploying the war file
          uzair Newbie

          soory . i place a wrong / in the import statement . typing error . but i have corrected it and am still getting the same error




          Jsp1



          <jsp:useBean id="helloBean" scope="request" class="Hello" />


          <h1>

          hello
          </h1>


          <%
          out.println(helloBean.sayHello());
          %>


          • 2. Re: Error deploying the war file
            jrmad2003 Newbie

            hi,

            to fixed your problem, the best way is to introduce a package structure to your example, to avoid naming conflicts. e.g. test.programming.Hello and then modify

            <jsp:useBean id="helloBean" scope="request" class="Hello" />

            to

            <jsp:useBean id="helloBean" scope="request" class="test.programming.Hello" />

            this should solve your problem.

            i hope it will help you.

            JR