RE: apache proxy/form action rewrite issue

2003-06-23 Thread Dirck Hecking
The magic ingredient here is to set redirect=true in the
struts-config.xml for the individual form mappings. -Dirck

-Original Message-
From: Chris Reeves [mailto:[EMAIL PROTECTED] 
Sent: Monday, June 23, 2003 9:36 PM
To: Struts User Mailing List
Subject: apache proxy/form action rewrite issue

I have a web app using struts that runs under tomcat, behind an apache
server using mod proxy.

My web app works exactly as expected when run directly against tomcat,
but
fails when I attempt to use actions behind apache.

For instance, my app (let's call it thing1) has a form at
/contact/index.jsp.

The action in the form, after being rewritten by struts, becomes
/thing1/contact/contact.do.

Is there any way to get around this? I don't want to throw more rules at
the
apache server, and I see no way (short of rewriting the from action with
javascript on the client) to get rid of the rewriting (at least, I've
found
no way thus far).

Any ideas? I've been banging my head on this one for a while now... I
have
some apps in struts 1.0 that just don't seem to suffer from this issue.

Thanks!

Chris




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


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



RE: apache proxy/form action rewrite issue

2003-06-23 Thread Dirck Hecking
Yes, I was referring to the action forwards. After closer reading I
understand the issue, you are trying to override the struts form action
in the generated html, thought you were trying to alter the location
displayed in the browsers location bar. Not sure. -Dirck

-Original Message-
From: Chris Reeves [mailto:[EMAIL PROTECTED] 
Sent: Monday, June 23, 2003 9:55 PM
To: Struts Users Mailing List
Subject: RE: apache proxy/form action rewrite issue

Are you referring to the action forward? I can put a redirect=true
there,
but it has no effect on rendering the form action. Or am I missing
something?

Chris

 -Original Message-
 From: Dirck Hecking [mailto:[EMAIL PROTECTED]
 Sent: Tuesday, June 24, 2003 12:44 AM
 To: Struts Users Mailing List
 Subject: RE: apache proxy/form action rewrite issue


 The magic ingredient here is to set redirect=true in the
 struts-config.xml for the individual form mappings. -Dirck

 -Original Message-
 From: Chris Reeves [mailto:[EMAIL PROTECTED]
 Sent: Monday, June 23, 2003 9:36 PM
 To: Struts User Mailing List
 Subject: apache proxy/form action rewrite issue

 I have a web app using struts that runs under tomcat, behind an apache
 server using mod proxy.

 My web app works exactly as expected when run directly against tomcat,
 but
 fails when I attempt to use actions behind apache.

 For instance, my app (let's call it thing1) has a form at
 /contact/index.jsp.

 The action in the form, after being rewritten by struts, becomes
 /thing1/contact/contact.do.

 Is there any way to get around this? I don't want to throw more rules
at
 the
 apache server, and I see no way (short of rewriting the from action
with
 javascript on the client) to get rid of the rewriting (at least, I've
 found
 no way thus far).

 Any ideas? I've been banging my head on this one for a while now... I
 have
 some apps in struts 1.0 that just don't seem to suffer from this
issue.

 Thanks!

 Chris




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


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


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


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



RE: How do I configure multiple struts-config files?

2003-06-23 Thread Dirck Hecking
If you are looking for a way to break up your definitions into
manageable chucks I would use jsp files to simply store bean definitions
and then % include % that jsp on the appropraite pages. This is better
for development too since you can change concrete definitions without
having to redeply the webapp.

-Dirck

-Original Message-
From: J, Sadhasivam (Cognizant) [mailto:[EMAIL PROTECTED] 
Sent: Monday, June 23, 2003 10:28 PM
To: Struts Users Mailing List
Subject: RE: How do I configure multiple struts-config files?

Means.. i didn't get u.

-Original Message-
From: PREETAM Balijepalli [mailto:[EMAIL PROTECTED]
Sent: Tuesday, June 24, 2003 10:53 AM
To: Struts Users Mailing List
Subject: RE: How do I configure multiple struts-config files?


hello you can have multiple with struts need to configure sub app
details in web.xml

-Original Message-
From: J, Sadhasivam (Cognizant) [mailto:[EMAIL PROTECTED]
Sent: Tuesday, June 24, 2003 10:53 AM
To: Struts Users Mailing List
Subject: RE: How do I configure multiple struts-config files?


I don't think struts will allow multiple configuration file and its
always one controller and one configuration file.

-Original Message-
From: Bob Byron [mailto:[EMAIL PROTECTED]
Sent: Tuesday, June 24, 2003 10:48 AM
To: [EMAIL PROTECTED]
Subject: How do I configure multiple struts-config files?


It doesn't seem like it should be this hard, but I am trying to
use multiple struts-config files.  I keep getting errors.
I have attached my configuration and error below.  Any help
is appreciated.  I am using struts 1.1 rc2.

By the way, whenever a config file can't be found, a
NullPointerException is thrown.  I hope a more meaningful
message is in the works.

 From web.xml
servlet
servlet-nameaction/servlet-name
servlet-classorg.apache.struts.action.ActionServlet/servlet-class
init-param
param-nameconfig/param-name
param-value/WEB-INF/struts-config.xml,/WEB-INF/abc-struts-config.xml/
param-value
/init-param


 From log:
23:52:19,585 WARN  [org.jboss.jbossweb] WARNING: action: Parsing error 
processing resource path 
/WEB-INF/struts-config.xml,/WEB-INF/abc-struts-config.xml
java.lang.NullPointerException
   at org.apache.crimson.parser.Parser2.parseInternal(Parser2.java:524)
   at org.apache.crimson.parser.Parser2.parse(Parser2.java:305)
   at
org.apache.crimson.parser.XMLReaderImpl.parse(XMLReaderImpl.java:442)
   at org.apache.commons.digester.Digester.parse(Digester.java:1299)
   at 
org.apache.struts.action.ActionServlet.initApplicationConfig(ActionServl
et.java:741)
   at
org.apache.struts.action.ActionServlet.init(ActionServlet.java:408)
   at javax.servlet.GenericServlet.init(GenericServlet.java:256)
   at

Thank You,
Bob


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


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


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