--- On Sat, 9/12/09, red dog <redwhite_...@yahoo.com> wrote: > From: red dog <redwhite_...@yahoo.com> > Subject: Re: scripting paramaters passed as parameters > To: "Struts Users Mailing List" <user@struts.apache.org> > Date: Saturday, September 12, 2009, 3:17 PM > First of all the subject should've > read "scripting events passed as parameters". > > I'm now responding to my own question :) - this will do > it - not sure if this is a bug in Struts2 or not though: > > <@s.textfield theme="simple" name="name1" id="id1" > cssClass="textfield" value="value1"> > <@s.param > name="onclick">myjsfunction();</@s.param> > </@s.textfield> >
What's wrong with <@s.textfield theme="simple" name="name1" id="id1" cssClass="textfield" value="value1" onclick="myjsfunction();" /> ? > > --- On Sat, 9/12/09, red dog <redwhite_...@yahoo.com> > wrote: > > > From: red dog <redwhite_...@yahoo.com> > Subject: scripting paramaters passed as parameters > To: user@struts.apache.org > Date: Saturday, September 12, 2009, 12:16 PM > > > Hello, > > I'm new to this mailing list although I'm using Struts2 for > quite some time. I am stuck right now and I decided to ask > a quick question: > > Is it possible to generate an input field (as well as any > other fields) by passing an onclick event for example as > parameter? It doesn't seem to be working for me... I'm using > Struts2.1.6 + freemarker as you can see bellow. > > <@s.textfield theme="simple" name="name1" id="id1" > cssClass="textfield" value="value1"> > <@s.param name="onclick" value="myjsfunction();" /> > </@s.textfield> > > Thank you. > > > > > > --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscr...@struts.apache.org For additional commands, e-mail: user-h...@struts.apache.org