setting classpath in fedora core 5
HI everyone
i am using tomcat Apache Tomcat/5.5.15
when i have compiled my testservlet file i got the following error message
[root@localhost classes]# javac TestingServlet.java
----------
1. ERROR in TestingServlet.java
(at line 1)
import javax.servlet.*;
^^^^^^^^^^^^^
The import javax.servlet cannot be resolved
----------
2. ERROR in TestingServlet.java
(at line 2)
import javax.servlet.http.*;
^^^^^^^^^^^^^
The import javax.servlet cannot be resolved
----------
3. ERROR in TestingServlet.java
(at line 6)
public class TestingServlet extends HttpServlet {
^^^^^^^^^^^
HttpServlet cannot be resolved to a type
----------
4. ERROR in TestingServlet.java
(at line 8)
public void doGet(HttpServletRequest request,
^^^^^^^^^^^^^^^^^^
HttpServletRequest cannot be resolved to a type
----------
5. ERROR in TestingServlet.java
(at line 9)
HttpServletResponse response)
^^^^^^^^^^^^^^^^^^^
HttpServletResponse cannot be resolved to a type
----------
6. ERROR in TestingServlet.java
(at line 10)
throws ServletException, IOException {
^^^^^^^^^^^^^^^^
ServletException cannot be resolved to a type
----------
6 problems (6 errors)[root@localhost classes]#
I found in one of the threads that BY SETTING THE CLASSPATH VARIABLE IT CAN BE RESOLVED
How to set the classpath variable in Fedora core 5
I read i a book that JAVA_HOME variuable also should be assigned a value i.e the poath where java is installed
Please explain me about setting the variable JAVA_HOME,CLASSPATH....etc[IF ANY] in detail
Bye
|