can not compile HelloServlet3.java with ServletUtilities
843840Sep 10 2002 — edited Sep 10 2002hi guys,
i have another compiling error with the ServletUtilities in the HelloServlet3.java.
the following is the error, please check it out
C:\SERVLETcode\hello3>javac HelloServlet3.java
HelloServlet3.java:23: cannot resolve symbol
symbol : variable ServletUtilities
location: class moreservlets.HelloServlet3
out.println(ServletUtilities.headWithTitle(title) +
^
1 error
i already check the classpath
classpath = .;c:\servletcode;tomcat4\common\lib\servlet.jar
i think it is correct because i can compile the HelloServlet1.java and HelloServlet2.java, except the HelloServlet3.java
so can anyone help me out of it....
thank you in advance....
the source code is herepackage moreservlets;
import java.io.*;
import javax.servlet.*;
import javax.servlet.http.*;
public class HelloServlet3 extends HttpServlet {
public void doGet(HttpServletRequest request,
HttpServletResponse response)
throws ServletException, IOException {
response.setContentType("text/html");
PrintWriter out = response.getWriter();
String title = "Hello (3)this is test3";
out.println(ServletUtilities.headWithTitle(title) +
"<BODY BGCOLOR=\"#FDF5E6\">\n" +
"<H1>" + title + "</H1>\n" +
"</BODY></HTML>");
}
}