This week's book giveaway is in the Agile and other Processes forum.
We're giving away four copies of The Mikado Method and have Ola Ellnestam and Daniel Brolund on-line!
See this thread for details.
The moose likes IDEs, Version Control and other tools and the fly likes How to run servlet program in eclipse Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Engineering » IDEs, Version Control and other tools
Reply Bookmark "How to run servlet program in eclipse" Watch "How to run servlet program in eclipse" New topic
Author

How to run servlet program in eclipse

Raghu ram
Ranch Hand

Joined: Oct 19, 2007
Posts: 34
Hello Frnds,

Anybody tell me to run the servlet program in eclipse IDE. What are the files should be downloaded and tell me what are the steps to import tomcat web container into eclipse.
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 26192
    
  66

Raghu,
Did you download the Tomcat Eclipse plugin yet?


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
Muhammad Saifuddin
Ranch Hand

Joined: Dec 06, 2005
Posts: 1318

here is on http://openknows.free.fr/


Saifuddin..
[Linkedin] How To Ask Questions On JavaRanch My OpenSource
Jesper de Jong
Java Cowboy
Bartender

Joined: Aug 16, 2005
Posts: 12928
    
    3

You don't need a special third-party plug-in for Eclipse to be able to control Tomcat from Eclipse.

Just install the Eclipse Java EE tools. You can do this using the update manager in Eclipse: Select Help / Software Updates / Find and Install, then choose "Search for new features to install" and click Next. Select "Europa Discovery Site" (for Eclipse 3.3) or "Callisto Discovery Site (for Eclipse 3.2) and click Finish. Eclipse starts searching for updates. You might need to select a mirror site. Choose one that is close to you.

When it's done searching, look in the list of updates and select J2EE Standard Tools (JST) and Web Standard Tools (WST). You might need to click "Select Required". Then click Finish and let Eclipse download and install the updates.

Note that instead of installing JST and WST through the update manager, you can also download the Eclipse IDE with those things pre-installed. Just download "Eclipse IDE for Java EE developers" from the Eclipse download page.

After installing and restarting Eclipse, select Window / Preferences. In the tree on the left choose Server / Installed Runtimes. On the right click the "Add" button, then select Apache / Apache Tomcat 6.0 (or a different version, depending on which Tomcat you are using). Click Next, and select the directory where you have Tomcat installed. Finally, click Finish and OK to close the preferences window.

Now you can make a Java EE project. Select File / New / Project... In the New Project selection window, choose Web / Dynamic Web Project. Enter the details for your project and let Eclipse create the new project.

After creating some JSPs in the WebContent directory of your project, right-click the project and select Run As / Run on Server. Select your Tomcat and click Finish. Eclipse now starts Tomcat and opens a browser inside Eclipse that points at the running Tomcat.


Java Beginners FAQ - JavaRanch SCJP FAQ - The Java Tutorial - Java SE 7 API documentation
Scala Notes - My blog about Scala
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: How to run servlet program in eclipse
 
Similar Threads
java fx
servlet with html problem
Creting Simple Servlet using Eclipse 5.0
(Q 4 sam) getting some exceptions Servlet cannot be resolved to a type in eclipse
How to run Servlet program on Eclipse.?