struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "James Mitchell" <jmitc...@telocity.com>
Subject RE: form w/out form bean
Date Wed, 19 Jun 2002 21:50:56 GMT
Yes, if you are using html:form, then you need a form decl in struts-config.

You can hack around it by using straight html form, but its only as pretty
as using straight jsp, which (gasp), I never recommend ;)

Depending on the size of your project, you are better off taking
struts-blank and adding your functionality page by page, then trying to
convert what you have over, but that's just my humble opinion.

Good luck

James Mitchell
Software Engineer\Struts Evangelist
Struts-Atlanta, the "Open Minded Developer Network"
http://struts-atlanta.open-tools.org

> -----Original Message-----
> From: Dennis Muhlestein [mailto:dennis@zserve.com]
> Sent: Wednesday, June 19, 2002 5:34 PM
> To: Struts-Atlanta@open-tools.org
> Subject: RE: form w/out form bean
>
>
> I'm on 1.0.2 which I neglected to mention.
>
> If I don't specify a name, then when the form is generated, I get a
> NullPointerException.  And something about the form not being able to
> resolve which class to instantiate.
>
> I just got around this by putting a
> type="org.apache.struts.action.ActionForm" in the form jsp tag.
>
> Probably not the best way but I'll change it anyway when I come back
> through and further implement struts and get rid of our servlets.
>
> I'm very interested in 1.1 DynaForm but I thought I'd just wait until
> 1.1 is released.
>
> Thanks for the input.
> -Dennis
>
>
> On Wed, 2002-06-19 at 15:37, James Mitchell wrote:
> > Yes you can.
> >
> > Specify your action in the struts-config, but do not use
> name="yourform".
> >
> > In your action you can still retrieve the request params as you
> would in a
> > servlet.
> >
> > Although its just tooooo easy to the DynaActionForm.  Have you
> considered
> > using it?
> >
> > James Mitchell
> > Software Engineer\Struts Evangelist
> > Struts-Atlanta, the "Open Minded Developer Network"
> > http://struts-atlanta.open-tools.org
> >
> > > -----Original Message-----
> > > From: Dennis Muhlestein [mailto:dennis@zserve.com]
> > > Sent: Wednesday, June 19, 2002 5:22 PM
> > > To: struts-user@jakarta.apache.org
> > > Subject: form w/out form bean
> > >
> > >
> > > Can I have a from with no form bean, just an action.
> > > It would make converting to struts easier but I can't seem to
> get it to
> > > work unless I create a form bean class for each form.  I just want to
> > > forward to the existing post url and later I'll go through and create
> > > form beans.
> > >
> > > Thanks
> > > Dennis
> > >
> > >
> > >
> > >
> > > --
> > > To unsubscribe, e-mail:
> > > <mailto:struts-user-unsubscribe@jakarta.apache.org>
> > > For additional commands, e-mail:
> > > <mailto:struts-user-help@jakarta.apache.org>
> > >
> > >
> >
> >
> > --
> > To unsubscribe, e-mail:
<mailto:struts-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail:
<mailto:struts-user-help@jakarta.apache.org>
>




--
To unsubscribe, e-mail:   <mailto:struts-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>


Mime
View raw message