Signup · Login
Stardeveloper.com  
Home · Tutorials · Forums · ASP.NET Newsletter Application · Web Hosting Plans · Faisal Khan's Blog · Contact
Forums : J2EE : JSP : After installing Tomcat 6.0 using this Tutorial, problem with Displaying Records Tutorial Signup · Login
Author Thread
After installing Tomcat 6.0 using this Tutorial, problem with Displaying Records Tutorial
Posted in tutorial: Installing, Configuring, & Running Tomcat 6.0 Servlet Container on Microsoft Windows, and Developing & Running your first JSP Page
·  srizvi1
User
Joined: 12 Dec 2007
Total Posts: 2

After installing Tomcat 6.0 using this Tutorial, problem with Displaying Records Tutorial

Posted: 12 Dec 2007
Hello Faisal,

I also posted a similar question in the "Displaying Records from the Database with Java Servlets" tutorial. I'm new to Java and needed some help, and have found your site in my search for learning JSP.

I'm having a hard time figuring out how to work on the "Displaying Records" tutorial after having installed Tomcat 6.0 using this tutorial.

I have two questions, but let me explain my set up before I ask them.

Now, after I completed this tutorial, my Tomcat is now installed here:
C:\apache-tomcat-6.0.14\

I set the JAVA_HOME and CATALINA_HOME variables as you said:
CATALINA_HOME : C:\apache-tomcat-6.0.14
JAVA_HOME : C:\Program Files\Java\jdk1.6.0_03

When I make the "Hello Faisal Khan" index.jsp page, I put it in:
C:\apache-tomcat-6.0.14\webapps\star
and I run it here:
http://localhost:8080/star/

That runs fine.

So knowing that this is my setup...

I'm following your "Displaying Records from the Database with Java Servlets" tutorial... and it's saying to create a DisplayServlet.java file and place it in:
/APP_NAME/WEB-INF/classes/com/stardeveloper/servlets/db/

So for me, I'm thinking I should put this in:
C:\apache-tomcat-6.0.14\webapps\star\WEB-INF\classes\com\stardeveloper\servlets\db

However, when I go to the page you say to go to:
http://localhost:8080/star/servlet/com.stardeveloper.servlets.db.DisplayServlet

I'm getting a:
The requested resource (/star/servlet/com.stardeveloper.servlets.db.DisplayServlet) is not available.

So my two questions are this:
1) Am I placing the DisplayServlet.java file where I'm supposed to?
2) Am I supposed to compile the DisplayServlet.java file prior to running the link you said? If I am supposed to compile first, using javac, I keep getting an error about package javax.servlet and package javax.servlet.http not existing. I believe I need to do something with the Tomcat provided servlet-api.jar file, but I'm not sure what exactly.

Could you (or anyone) please help me?
Want to leave a comment? Login or Register for free!

Users Subscribed To This Thread
srizvi1  

Users Who Have Visited This Thread In Last 24 Hours
2 Visitors

Login to post a comment or start a new thread
UserName Or Email Address:       Password:       Auto-Login:    
· Create New User Account
· Send Forgotten Password by Email
 
© 1999 - 2010 Stardeveloper.com, All Rights Reserved.