> If I understand you correctly, those 2 pages
> would then be _nearly_ identical - the main
> difference would be that one may have a form
> with:

Yes the two pages are similar.
Here's a good example:
http://husted.com/struts/tips/002.html
tho the husted site has been down for a couple days....
>
>     <input name="op_type" value="create"/>
>
> while the other one may have:
>
>     <input name="op_type" value="update"/>
>
>
> Is that what you are saying?
>
> I think I was just forcing the use of
> DispatchAction in my particular case.  Yes,
> when 2 operations are _really_ similar, then
> this will work, but when they are not very
> similar, then one may be better of just
> having 2 distinct Action classes.
>
> Thanks,
> Otis
>
>
> ---- On Fri, 27 Dec 2002, Max Kremer
> ([EMAIL PROTECTED]) wrote:
>
> > Hey Otis,
> >
> > > Multiple but identical pages, is what you
> > > are saying?
> > > If that is so, then I am doing something
> > > wrong, and that is probably that I am
> > > forcing the use of DispatchAction when I
> > > should really be using 2 distinct Action
> > > classes instead.
> >
> > No, you don't multiple identical pages.
> There should be no need for that.
> > The page should dynamically decide which
> method in the dispatch to call by
> > setting a value for the parameter name
> defined by the "parameter" attribute
> > in the action config in the struts-config.xml.
> > For example, I have the following action:
> >
> > <action path="/part_edit_save"
> type="PartEditSaveAction" name="partListForm"
> > scope="request" input="/MainMenu.jsp"
> parameter="op_type">
> >
> > So I set the parameter called "op_type" to
> be the name of the action method
> > that should process the form.
> > So if op_type = save then the save method
> is called.
> >
> >
> >
> >
> >
>
>
> ________________________________________________
> Get your own "800" number
> Voicemail, fax, email, and a lot more
> http://www.ureach.com/reg/tag
>
> --
> To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>
>
> -
>
>


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

Reply via email to