Re: Tomcat 5 is live, but won't display pages for me.

2004-05-07 Thread QM
On Fri, May 07, 2004 at 04:01:30PM -0400, Parker, Mike wrote:
: I have seen in a tutorial:
: http://www.dougsparling.com/comp/howto/Ent...ux-HOWTO-4.html

Could you provide the full URL, please?
It would be easier to see what may have gone wrong if the rest of us can
see all of the steps you took.

You should also list which versions of Tomcat and the JDK you're
running.


: I took the helloJava.class file, and put it in the classes
: ($CAT_HOME/webapps/sparling/WEB-INF/classes ) directory.

If you're running Tomcat 5, you'll have to put the class in a pacakge.
This will not work as-is.


: The instructions said that now I can run this servlett by going to :
: http://localhost:8080/sparling/servlet/HelloWorld

Chances are, your instructions assume the invoker servlet is loaded.
It's off by default in Tomcat 5, and (IIRC think) Tomcat 4.1.

Check out Sun's servlet spec for how to use a web.xml file that maps
servlet classes to URIs.  That should solve the problem.

-QM

-- 

software  -- http://www.brandxdev.net
tech news -- http://www.RoarNetworX.com


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Tomcat 5 is live, but won't display pages for me.

2004-05-07 Thread Parker, Mike
 



 Hi, using RH Linux 9 (blag), I have jsdk, ANT, and Tomcat loaded. Jsdk let me run 
helloWorld.java from command line, and Tomcat allows me to view their welcome page at 
localhost:8080. 
 
I have seen in a tutorial: http://www.dougsparling.com/comp/howto/Ent...ux-HOWTO-4.html
that i should be able to run java servlets by creating a  at 
$CATALINA_HOME/conf/server.xml , and I have created that path there:



and then created the necessary directory path :

# cd $CATALINA_HOME
# cd webapps
# mkdir sparling
# cd sparling
# mkdir WEB-INF
# cd WEB-INF
# mkdir classes
 
I took the helloJava.class file, and put it in the classes 
($CAT_HOME/webapps/sparling/WEB-INF/classes ) directory.
 
The instructions said that now I can run this servlett by going to : 
http://localhost:8080/sparling/servlet/HelloWorld  
 
in my browser (mozilla). 
 
But when I do this, I get : The requested resource (/sparling/servlet/HelloWorld) is 
not available. 
 
Can anyone tell what might be wrong ?
 
Additionally, I am not able to get a hello.html page to display using the method 
explained to me in another tutorial:  
 
The instructions said if I put an HTML file in directory:
install_dir/webapps/ROOT or install_dir/webapps/ROOT/somePath 
 
that I could access them with http://localhost/filename or 
http://localhost/somePath/filename.
 
I put the file in that director, and then used http://localhost:8080/test1.html in my 
browser, and was giiven: The requested resource (/test1.html) is not available.
 
Any suggestions regarding what I should do, or where I can get the information I need 
to get Tomcat running pages and Java Servlets?
 
thanks for listening,
 
Mike P 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]