4 Replies Latest reply on Feb 3, 2005 3:14 PM by bapha

    jsp not compiling

    bapha

      Greetings

      Firstly, I have had a look at http://www.jboss.org/wiki/Wiki.jsp?page=UnableToCompileJSP and this didnt solve my problem - I have the Java_home set correctly.

      The jsp page I am trying to run is:

      
      <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
      <HTML>
      <HEAD><TITLE>JSP Test Page</TITLE></HEAD>
      <BODY BGCOLOR="#FDF5E6">
      <H2><%
       out.print("Hello World");
      %></H2>
      </BODY></HTML>
      
      


      anyone know why I am getting these errors:

      type Exception report

      message

      description The server encountered an internal error () that prevented it from fulfilling this request.

      exception

      org.apache.jasper.JasperException: Unable to compile class for JSP

      Generated servlet error:
      C:\jboss\server\default\work\jboss.web\localhost\freedomair\org\apache\jsp\index_jsp.java:3: package javax.servlet does not exist
      import javax.servlet.*;



        • 1. Re: jsp not compiling
          danl_thompson

          Make sure javax.servlet.* is in the classpath.

          it can be found in javax.servlet.jar in the jboss server, or in the sun jdk, depending on how you are compiling.

          • 2. Re: jsp not compiling
            bapha

            thanks Danl

            Thats what I thought it would be, but this is my class_path

            C:\jboss\server\default\lib\javax.servlet.*

            I have also tried:

            C:\jboss\server\default\lib too but with no joy.

            Do you know how I should write the class path?

            Thanks

            • 3. Re: jsp not compiling
              danl_thompson

              You using ant? or what?

              • 4. Re: jsp not compiling
                bapha

                HI, and thanks again for your help.

                I didnt realise I need ant - I thought Jboss was able to compile JSP pages - is this not correct?

                Please forgive my lack of understanding but I thought that Tomcat can compile JSP pages and that Tomcat is part of Jboss?

                But if Ant is needed - why isnt it part of Jboss????