Is it possible to specify a global 404 error page for all apps under tomcat 4

2002-07-22 Thread John Regan

Good afternoon,
I am trying to specify a generic 404 error page for all webapps in tomcat 4.
I added the following entry to tomcathome\conf\web.xml:

404
/csa/jsp/Error404.jsp
   
under the default welcome files list and it doesn't work(just the generic
tomcat page not found page comes up).  csa is a directory under webapps.  Is
there a way to make this work??

Thanks in advance for any help,
JBR
"breakdancing will never go out of style."
Larry Crantz '87



RE: Is it possible to specify a global 404 error page for all app s un der tomcat 4

2002-07-22 Thread John Regan

John,
Thanks for the reply.  I believe it's in the right order because error-page
comes right after the welcome file list in the DTD, plus it works in a
web.xml deployed under the webapps directory.  Any other suggestions?

-Original Message-
From: Turner, John [mailto:[EMAIL PROTECTED]]
Sent: Monday, July 22, 2002 1:44 PM
To: 'Tomcat Users List'
Subject: RE: Is it possible to specify a global 404 error page for all
app s un der tomcat 4



Make sure you follow the DTD.  The containers in web.xml (like "error-page")
have to go in a very specific order.

John Turner
[EMAIL PROTECTED]


-Original Message-
From: John Regan [mailto:[EMAIL PROTECTED]]
Sent: Monday, July 22, 2002 4:43 PM
To: Tomcat User Group (E-mail)
Subject: Is it possible to specify a global 404 error page for all apps
un der tomcat 4


Good afternoon,
I am trying to specify a generic 404 error page for all webapps in tomcat 4.
I added the following entry to tomcathome\conf\web.xml:

404
/csa/jsp/Error404.jsp
   
under the default welcome files list and it doesn't work(just the generic
tomcat page not found page comes up).  csa is a directory under webapps.  Is
there a way to make this work??

Thanks in advance for any help,
JBR
"breakdancing will never go out of style."
Larry Crantz '87

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



"Split Thread" with 2 browsers

2001-12-04 Thread John Regan


Desired functionality:
User opens browser, clicks through several pages as a certain "user type"
then opens a second browser because they want to be a different "user type".
The user should be able to proceed in either browser without session
information being overwritten in the other browser's session.  

Has anyone implemented any similar functionality?

Note: using tomcat 4.x as http server and JSP container.




RE: "Split Thread" with 2 browsers

2001-12-04 Thread John Regan

thank you Conor for the quick response.

this works if the second browser is launched from the desktop but if the
second browser is launched using Ctrl+N from the first browser both browsers
share the same session.  is there any way around this?  

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 04, 2001 10:50 AM
To: [EMAIL PROTECTED]
Subject: RE: "Split Thread" with 2 browsers


You should be able to implement this functionality using URL rewriting where
the session identifier is stored on the query string rather than as a cookie
in the browser.

In this way once the user opens a new window and logs in again you can
create a new session in the second browser.

Conor.

-Original Message-----
From: John Regan [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 04, 2001 9:08 AM
To: Tomcat User Group (E-mail)
Subject: "Split Thread" with 2 browsers



Desired functionality:
User opens browser, clicks through several pages as a certain "user type"
then opens a second browser because they want to be a different "user type".
The user should be able to proceed in either browser without session
information being overwritten in the other browser's session.  

Has anyone implemented any similar functionality?

Note: using tomcat 4.x as http server and JSP container.


--
To unsubscribe:   <mailto:[EMAIL PROTECTED]>
For additional commands: <mailto:[EMAIL PROTECTED]>
Troubles with the list: <mailto:[EMAIL PROTECTED]>



How long can the session ID get in 4.0?

2001-12-10 Thread John Regan




How come I can't remove from server.xml?

2001-12-21 Thread John Regan

i am using 4.0 and want to remove this service from server xml but when i
take it out tomcat will start up(opens command window deploys some files
then gets hung).
Does tomcat need this service, because i don't believe i need it?

thank you in advance for any help!!  happy holidays!



RE: How come I can't remove from server.xml?

2001-12-21 Thread John Regan

thank you for the quick response.
it wasn't hung, it worked fine when i removed the whole service.  i thought
it was hung because i didn't see the Apache Tomcat/4.0 print out in the
command prompt.  thanks again.

-Original Message-
From: Dieter Kaltenbach [mailto:[EMAIL PROTECTED]]
Sent: Friday, December 21, 2001 12:05 PM
To: Tomcat Users List
Subject: Re: How come I can't remove  from
server.xml?


when I delete the whole service tag from the server.xml only the Tomcat
standalone service is started. I am using Tomcat 4.0.1 by the way


  
    
  

John Regan wrote:

> i am using 4.0 and want to remove this service from server xml but when i
> take it out tomcat will start up(opens command window deploys some files
> then gets hung).
> Does tomcat need this service, because i don't believe i need it?
>
> thank you in advance for any help!!  happy holidays!


--
To unsubscribe:   <mailto:[EMAIL PROTECTED]>
For additional commands: <mailto:[EMAIL PROTECTED]>
Troubles with the list: <mailto:[EMAIL PROTECTED]>



Manager App in 4.0

2002-03-13 Thread John Regan

I have been running an application in 4.0 for several months and want to use
the manager application.
I can't seem to get to the manager application.  When i try a simple command
like:
http://localhost:8100/manager/list
I get 404 page not found.  Does anybody have any suggestions?
Under the manager folder there is only a web.xml file, is that right?

Thanks in advance for any help!



RE: Manager App in 4.0

2002-03-13 Thread John Regan

thank you for the quick response.
yes, i did change the default port to 8100.

I made the change and restarted but i still get same thing: 404 Page Not
Found

Any other suggestions?
My file is called tomcat-users.xml should it be conf.tomcat-users.xml?

thanks again.


-Original Message-
From: Ashutosh Aman [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, March 13, 2002 2:25 PM
To: Tomcat Users List
Subject: Re: Manager App in 4.0



go to $CATALINE_HOME/conf.tomcat-users.xml file where CATALINA_HOME is the
directory where you have installed Tomcat.

Add one line


or you can insert the role manager in one of the existing role.

shutdown and start Tomcat and then
http://localhost:8100/manager/list

I see you are using port 8100. Default is 8080 unless you have changed it.

Good luck
Aman


--

This e-mail may contain confidential and/or privileged information. If you
are not the intended recipient (or have received this e-mail in error)
please notify the sender immediately and destroy this e-mail. Any
unauthorized copying, disclosure or distribution of the material in this
e-mail is strictly forbidden.



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 



RE: Manager App in 4.0

2002-03-14 Thread John Regan
Title: RE: Manager App in 4.0





still struggling to get the manager working.  have followed all suggestions, don't get 404 any more but now it just hangs when i try to access the manager

http://jbrpc:8025/manager/list


Can someone take a look @ my server.xml and tomcat-users.xml and see if there are any glaring mistakes?




-Original Message-
From: Jean-Luc BEAUDET [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 14, 2002 2:26 AM
To: Tomcat Users List
Subject: Re: Manager App in 4.0



Scott Shorter a écrit :


> I would speculate that that was a typo for
> $CATALINA_HOME/conf/tomcat-users.xml
> -
> Scott
>
> > -Original Message-
> > From: John Regan [mailto:[EMAIL PROTECTED]]
> > Sent: Wednesday, March 13, 2002 6:00 PM
> > To: 'Tomcat Users List'
> > Subject: RE: Manager App in 4.0
> >
> >
> > thank you for the quick response.
> > yes, i did change the default port to 8100.
> >
> > I made the change and restarted but i still get same thing:
> > 404 Page Not Found
> >
> > Any other suggestions?
> > My file is called tomcat-users.xml should it be conf.tomcat-users.xml?
> >
> > thanks again.
> >
> >
> > -Original Message-
> > From: Ashutosh Aman [mailto:[EMAIL PROTECTED]]
> > Sent: Wednesday, March 13, 2002 2:25 PM
> > To: Tomcat Users List
> > Subject: Re: Manager App in 4.0
> >
> >
> >
> > go to $CATALINE_HOME/conf.tomcat-users.xml file where
> > CATALINA_HOME is the directory where you have installed Tomcat.
> >
> > Add one line
> > 
> >
> > or you can insert the role manager in one of the existing role.
> >
> > shutdown and start Tomcat and then http://localhost:8100/manager/list
> >
> > I see you are using port 8100. Default is 8080 unless you
> > have changed it.
> >
> > Good luck
> > Aman
> >
> >
> > --
> >
> > This e-mail may contain confidential and/or privileged
> > information. If you are not the intended recipient (or have
> > received this e-mail in error) please notify the sender
> > immediately and destroy this e-mail. Any unauthorized
> > copying, disclosure or distribution of the material in this
> > e-mail is strictly forbidden.
> >
> >
> >
> > --
> > To unsubscribe:   <mailto:[EMAIL PROTECTED]>
> > For additional commands: <mailto:[EMAIL PROTECTED]>
> > Troubles with the list: <mailto:[EMAIL PROTECTED]>
> >
>
> --
> To unsubscribe:   <mailto:[EMAIL PROTECTED]>
> For additional commands: <mailto:[EMAIL PROTECTED]>
> Troubles with the list: <mailto:[EMAIL PROTECTED]>


I paste the answer i did to somebody else.
It is for the Tomcat_Apache Engine, but it works the same for the
Tomcat_Standalone part.



It had been such a mess all around it !


I give yu my code:



  


    


   port="8025" minProcessors="5" maxProcessors="75"
   enableLookups="true" appBase="webapps"
   acceptCount="10" debug="0"/>


    
    
    name="Apache" appBase="webapps" defaulthost="MyServer.com" >


    


   
   directory="Logs" prefix="local_access_log." suffix=".txt"
   pattern="common" />


    
    
    prefix="apache_log." suffix=".txt"
    timestamp="true"/>


    
    


    
unpackWARs="true" >


 
 


    


    


  



The best way is via the manager facilities.
To do so yu DO have to declare the Host, like in the code below, so that it


is available thru the warp connector via:


WebAppDeploy manager conn /manager/


Hope this help.


Jean-Luc B :O)




--
To unsubscribe:   <mailto:[EMAIL PROTECTED]>
For additional commands: <mailto:[EMAIL PROTECTED]>
Troubles with the list: <mailto:[EMAIL PROTECTED]>


 




server.xml
Description: Binary data


tomcat-users.xml
Description: Binary data

--
To unsubscribe:   <mailto:[EMAIL PROTECTED]>
For additional commands: <mailto:[EMAIL PROTECTED]>
Troubles with the list: <mailto:[EMAIL PROTECTED]>


RE: Manager App in 4.0

2002-03-14 Thread John Regan

thanks.  somewhere along the line i must have screwed up my server.xml.
works fine now.  NT and 4.0.
thanks again

-Original Message-
From: Ashutosh Aman [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 14, 2002 11:24 AM
To: Tomcat Users List
Subject: RE: Manager App in 4.0



It works right out of the box.
Install Tomcat and just modify tomcat-users.xml and then start Tomcat.
Try http://localhost:8080/manager/list and it will work.
you can also replace localhost with the name of your computer in the
network.

You can then change the port and other stuff later.

What is your platform and version of Tomcat?


--

This e-mail may contain confidential and/or privileged information. If you
are not the intended recipient (or have received this e-mail in error)
please notify the sender immediately and destroy this e-mail. Any
unauthorized copying, disclosure or distribution of the material in this
e-mail is strictly forbidden.



--
To unsubscribe:   
For additional commands: 
Troubles with the list: 



Tomcat Session ID handling??

2002-04-23 Thread John Regan

*   I am concerned about how Tomcat identifies whether or not a page hit
is part of an old or new session.  If you come back the next day and type
yesterday's jsessionid= value onto your URL line, will Tomcat be tricked
into thinking its the same session?  If you bookmark a page so that the
jsessionid= value is saved as part of the bookmark, will Tomcat think it's
the same old session every time you exercise the bookmark?




RE: Off topic:cookies nightmare!!!!!!!!

2002-04-29 Thread John Regan

THAT WAS IT!!  Scott, thank you so much for the quick response, and thank
you Craig for the clarification!!  Happy Monday.

-Original Message-
From: Craig R. McClanahan [mailto:[EMAIL PROTECTED]]
Sent: Monday, April 29, 2002 2:49 PM
To: Tomcat Users List
Cc: [EMAIL PROTECTED]; Struts Users (E-mail)
Subject: Re: Off topic:cookies nightmare




On Mon, 29 Apr 2002, pixel wrote:

> Date: Mon, 29 Apr 2002 17:42:13 -0400
> From: pixel <[EMAIL PROTECTED]>
> Reply-To: Tomcat Users List <[EMAIL PROTECTED]>
> To: [EMAIL PROTECTED]
> Cc: Tomcat Users List <[EMAIL PROTECTED]>,
>  "Struts Users (E-mail)" <[EMAIL PROTECTED]>
> Subject: Re: Off topic:cookies nightmare
>
> John,
>
> I had a similar problem, which seem to be resovled by explicitly setting
> the path of the cookie to "/" before adding it to the response.
>
> Cookie userCookie = new Cookie("U_ID", userId);
> userCookie.setMaxAge(94608);
> userCookie.setPath("/");
> httpResp.addCookie(userCookie);
>
> After reading the Servlet docs, it seems the behaviour for setting a
> cookie without first setting it's path is undefinded. I've found that
> with Tomcat, new Cookies use the current URL of the request instead of
> the "/" when a path is not specified. I also believe there may have been
> a few bugs with previous versions of Tomcat and Cookies which have been
> resolved with newer versions.
>

Setting the cookie path to "/" will cause this cookie to be sent back to
*all* web applications on your server, not just yours.  It is safer to set
the cookie path to return just to your web application:

  userCookie.setPath(request.getContextPath());

> Hope this helps,
>
> ~Scott

Craig



Off topic:cookies nightmare!!!!!!!!

2002-04-29 Thread John Regan

I am John Regan.

Environment:
NT
IE 5.0
Tomcat 4.0
Struts 1.0

When a user requests our index page we write a pagehit sequence # to the
client's cookie through the following code:
//no cookie exits
   else {
Cookie pcookie = new Cookie("P",r.getPagehitcode());
pcookie.setMaxAge(60*60*24*365);//1 year
response.addCookie(pcookie);  
   } 
which works fine, I look in my cookies directory and find a file named
jbr@jsp[1].txt(where does it grab this name from?) which contains the
correct value for "P".
The user clicks on a link on the homepage, this where things start to go
very wrong.  In the action class I loop through cookie values in the
following manner:

Cookie[] cookies = request.getCookies();
Cookie cookie;
   Cookie schangecookie = null;
   if (cookies != null) {
for(int i=0; i


Re: question about WEB-INF/lib

2001-07-24 Thread john regan

(a newbie speaks...)

Are you looking for a workaround? When I saw this problem, I copied the jar
file to tomcat's lib directory and it worked. I thought maybe I had misread
something in the doc.

Like I said, I'm new here, but I agree that this is not what I expected to do. 

-john

Dmitri Colebatch wrote:
> 
> I can verify it does work.  I dont have any suggestions though - sorry.
> 
> cheesr
> dim
> 
> On Tue, 24 Jul 2001 [EMAIL PROTECTED] wrote:
> 
> >
> > I see this problem, too. I'm using Tomcat 3.2.x. It appears to me to be a
> > bug.
> > I've seen others with this problem on this mailing list. Can anyone verify
> > that this actually does work?
> > (Just trying to add some weight to your claim and get it fixed if it is a
> > bug. :o)
> >
> > Thanks,
> > Dave
> >
> >
> >
> >
> >
> > Joseph D Toussaint <[EMAIL PROTECTED]> on 07/24/2001 11:55:44 AM
> >
> > Please respond to [EMAIL PROTECTED]
> >
> > To:   [EMAIL PROTECTED]
> > cc:
> >
> > Subject:  question about WEB-INF/lib
> >
> >
> > It's my understanding that any jar files in the WEB-INF/lib directory
> > should be found by the container when the app is deployed - however I
> > havea  jdbc driver in that directory and I'm getting a class not found
> > exception.
> >
> >
> > When ever I have set up tomcat before I've always edited the tomcat.sh
> > script so search all the WEB-INF/lib directories for every web
> > application - however this time I'd like to do it right.
> >
> >
> > Thanks!
> >
> >
> > joe
> >
> >
> > --
> > ##
> > # Joseph Toussaint   #
> > # Caribou Lake Software  #
> > # http://www.cariboulake.com #
> > # [EMAIL PROTECTED]   #
> > # 952-837-98029  #
> > ##
> >
> >
> >
> >
> >
> >
> >
> >



Re: browsing web pages served by Tomcat 3.2.3 using aMACINTOSH ?

2001-09-05 Thread john regan

I saw something similar before I set up Tomcat to run under apache. Are you
accessing the page from a different computer? Perhaps on the host machine you
are entering the ":8080", but your forgetting this on the Mac. ...that's what
I did. :-/ 

Tim O'Neil wrote:
> 
> At 02:02 PM 9/5/2001, you wrote:
> >has anyone accessed webpages served by tomcat, using IE or Netscape ?
> >I tried to access a simple JSP page served by tomcat 3.2.3 and in IE, I got
> >back the page without images, and on Netscape I got the actual JSP file !
> 
> Yes. no problems.
> 
> >any ideas ?
> 
> Site error. Time to debug.



Display JSP files in browser?

2001-09-05 Thread john regan

I would like to display a jsp file in a browser, similar to what Marty Hall
does at
http://archive.coreservlets.com/JSP-Code/Greetings.jsp

Using apache/tomcat. I tried moving the file to the apache html directory, but
I still get a 404 error from Tomcat. Obviously, apache will forward all jsp
files to tomcat. If the file is not found by Tomcat, I get a 404. If it is
registered, then the page executes the jsp code. Either way, the browser
doesn't view the jsp code.

I thought there was a thread on this last month, but I couldn't turn it up in
a search.

Thanks.