me ajudem, e me digam por q não estou conseguindo executar esse servlet…
instalei o tomcat… está funcionando ok…
código do servlet…
//criando pagina cliente
import javax.servlet.<em>;
import javax.servlet.http.</em>;
import <a href="http://java.io">java.io</a>.*;
public class HSTeste extends HttpServlet{
public void doGet(HttpServletRequest request,
HttpServletResponse response)
throws ServletException, IOException
{
PrintWriter output;
response.setContentType("text/html");
output = response.getWriter();
StringBuffer buf = new StringBuffer();
buf.append("<HTML><HEAD><TITLE>
");
buf.append(“A SIMPLE SERVLET EXAMPLE
“);
buf.append(”</TITLE></HEAD><BODY>
“);
buf.append(”<H1>Welcome to Servlets!</H1>
“);
buf.append(”</BODY><HTML>”);
output.println(buf.toString());
output.close();
}
}
o código html
!-HSTeste.html->
<HTML>
<HEAD>
<TITLE>
Servlet HTTPPGET Example
</TITLE>
</HEAD>
<BODY>
<FORM
ACTION=“http://localhost:8080/HSTesteapp/HSTeste”
METHOD=“GET”>
<P>Click the button to have the servlet send
an HTML document</P>
<INPUT TYPE=“submit” VALUE=“Get HTML Document”>
</FORM>
</BODY>
</HTML>
o q tinha no tutorial do tomcat era q teria q criar um diretorio com o nome da aplicação dentro do webapps… no meu exemplo o diretorio HSTesteapp… e dentro deste criar um diretório WEB-INF(dentro um arquivo web.xml, só q criei um .html)e outro diretorio classes onde coloquei o .class … só q quando tento executar o tomcat da o seguinte erro…
Apache Tomcat/4.0.4 - HTTP Status 404 - /HSTeste
type Status report
message /HSTeste
description The requested resource (/HSTeste) is not available.
por favor me ajudem!!!
agradeço

