Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / October 2007

Tip: Looking for answers? Try searching our database.

'Hello world' servlet with Sun Java System Application Server

Thread view: 
Thomas Armstrong - 02 Oct 2007 21:46 GMT
Hi.

I'm trying to create a simple "Hello World" servlet to be served with
Sun Java System Application Server Platform Edition 8.2.

I installed it ok on Linux:
/opt/SUNWappserver/
http://localhost:8080 works fine
http://localhost:4848 works fine

But I'm not able to fin the way to serve my 'HelloWorld' servlet:
-------
import java.io.*;

import javax.servlet.http.*;
import javax.servlet.*;

public class HelloServlet extends HttpServlet {
 public void doGet (HttpServletRequest req,
                    HttpServletResponse res)
   throws ServletException, IOException
 {
   PrintWriter out = res.getWriter();

   out.println("Hello, world!");
   out.close();
 }
}
--------------

No idea about where to copy it or how to modify 'web.xml' file.

Any suggestion?
Lew - 02 Oct 2007 22:37 GMT
> Hi.
>
[quoted text clipped - 9 lines]
>
> Any suggestion?

<http://java.sun.com/javaee/5/docs/tutorial/doc/bnadx.html#bnadz>

Signature

Lew



Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.