You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Alain Hubert <al...@iconmedialab.com> on 2001/01/04 12:41:37 UTC

action.xml and struts-config.xml

I'm using struts last build with Tomcat.

A newbie question. I'm looking at the different struts examples
coming with the distribution and I'm trying to figure out why
action.xml is sometimes used and why it is sometimes not.
For instance, in the struts-example application, action.xml
and struts-config.xml are used and it seems that struts-config.xml
include quite the same content (action mappings) than action.xml.

Could someone explain that and tell me what is recommended? Can
someone tell me the purpose of each file? I see also a difference of
syntax between the 2 files, is there any documentation about that?

Thanks in advance.

-alain

Re: action.xml and struts-config.xml

Posted by Ted Husted <ne...@husted.com>.
struts-config.xml is the successor to action.xml. action.xml is
deprecated, and 
won't be supported past the 1.0 release.

To use the new format, the ActionServlet validate property should be
set to true. 

struts-config.xml is basically a superset of action.xml, so where you
see that 
mentioned in the 0.5 User Guide, you can substitute struts-config.xml.

Right now, the best documentation for struts-config.xml is the dtd 
< http://localhost:8080/struts-documentation/dtds/struts-config_1_0.dtd
>

You will see that it is well commented.

Craig is looking for help with creating more documentation for the 1.0
package. 
I will try as soon as I can, but of course other volunteers are also
encouraged to 
jump in.

See also 

<
http://www.mail-archive.com/struts-user@jakarta.apache.org/msg01475.html
 >


<
http://www.mail-archive.com/struts-user@jakarta.apache.org/msg00321.html
 >


-- Ted Husted, Husted dot Com, Fairport NY USA.
-- Custom Software ~ Technical Services.
-- Tel 716 425-0252; Fax 716 223-2506.
-- http://www.husted.com/