Re: Checkbox handling in Maverick

Scott Hernandez <[email protected]> Thu, 10 Jul 2008 12:46:01 -0700
Newsgroups gmane.comp.web.maverick.general
Message-ID <[email protected]>
--===============1546351342==
Content-Type: multipart/alternative;
	boundary="_3bb14375-af37-413a-b139-f781bb5ee7d4_"

--_3bb14375-af37-413a-b139-f781bb5ee7d4_
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

There is an example of this in the pig sample.
=20
Look at line 25 of http://mav.cvs.sourceforge.net/mav/pig/src/java/org/info=
hazard/pig/web/controller/GalleryManageSubmit.java?revision=3D1.3&view=3Dma=
rkup where the extractPrefixedIds function is used. It returns an array of =
the checked values. The function is defined in this helper class http://mav=
.cvs.sourceforge.net/mav/pig/src/java/org/infohazard/pig/web/support/Contro=
llerBase.java?revision=3D1.3&view=3Dmarkup.I hope this helps.
=20



From: [email protected]: [email protected]: Thu=2C 10 Jul=
 2008 12:38:37 -0700Subject: [Mav-user] Checkbox handling in Maverick



Hi=2C
=20
   I am new to Maverick and have been playing around with it since a few we=
eks. I basically have a page that displays a bunch of checkboxes (with the =
same name but different values). Upon submitting the form that contains thi=
s checkbox group=2C I need to identify all the checkboxes that were selecte=
d in the controller pertaining to the action. I know that a single checkbox=
 is treated as a Boolean and I can use is<field name> to get its value and =
the corresponding setter is set<field name> but how do I use getter/setter =
for checkbox group sharing the same name? A code sample would really help.
=20
-Amol
 =

--_3bb14375-af37-413a-b139-f781bb5ee7d4_
Content-Type: text/html; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<html>
<head>
<style>
.hmmessage P
{
margin:0px=3B
padding:0px
}
body.hmmessage
{
FONT-SIZE: 10pt=3B
FONT-FAMILY:Tahoma
}
</style>
</head>
<body class=3D'hmmessage'>There is an example of this in the pig sample.<BR=
>
&nbsp=3B<BR>
Look at line 25 of <A href=3D"http://mav.cvs.sourceforge.net/mav/pig/src/ja=
va/org/infohazard/pig/web/controller/GalleryManageSubmit.java?revision=3D1.=
3&amp=3Bview=3Dmarkup">http://mav.cvs.sourceforge.net/mav/pig/src/java/org/=
infohazard/pig/web/controller/GalleryManageSubmit.java?revision=3D1.3&amp=
=3Bview=3Dmarkup</A>&nbsp=3Bwhere the <SPAN class=3D"hl kwd">extractPrefixe=
dIds function is used. It returns an array of the checked values. The funct=
ion is defined in this helper class <A href=3D"http://mav.cvs.sourceforge.n=
et/mav/pig/src/java/org/infohazard/pig/web/support/ControllerBase.java?revi=
sion=3D1.3&amp=3Bview=3Dmarkup">http://mav.cvs.sourceforge.net/mav/pig/src/=
java/org/infohazard/pig/web/support/ControllerBase.java?revision=3D1.3&amp=
=3Bview=3Dmarkup</A>.</SPAN><BR><BR>I hope this helps.<BR>
&nbsp=3B<BR>

<HR id=3DEC_stopSpelling>
<BR>
From: [email protected]<BR>To: [email protected]<BR>Date: Thu=
=2C 10 Jul 2008 12:38:37 -0700<BR>Subject: [Mav-user] Checkbox handling in =
Maverick<BR><BR><BR>
<META content=3D"Microsoft SafeHTML" name=3DGenerator>
<STYLE>
.ExternalClass .EC_EmailQuote
{margin-left:1pt=3Bpadding-left:4pt=3Bborder-left:#800000 2px solid=3B}
</STYLE>
<FONT face=3D"Calibri=2C sans-serif" size=3D2>
<DIV>Hi=2C</DIV>
<DIV>&nbsp=3B</DIV>
<DIV>&nbsp=3B&nbsp=3B I am new to Maverick and have been playing around wit=
h it since a few weeks. I basically have a page that displays a bunch of ch=
eckboxes (with the same name but different values). Upon submitting the for=
m that contains this checkbox group=2C I need to identify all the checkboxe=
s that were selected in the controller pertaining to the action. I know tha=
t a single checkbox is treated as a Boolean and I can use <B>is&lt=3Bfield =
name&gt=3B</B> to get its value and the corresponding setter is <B>set&lt=
=3Bfield name&gt=3B</B> but how do I use getter/setter for checkbox group s=
haring the same name? A code sample would really help.</DIV>
<DIV>&nbsp=3B</DIV>
<DIV>-Amol</DIV>
<DIV>&nbsp=3B</DIV></FONT></body>
</html>=

--_3bb14375-af37-413a-b139-f781bb5ee7d4_--


--===============1546351342==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
--===============1546351342==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
%(real_name)s mailing list
%(real_name)s@%(host_name)s
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s
Archives are available at http://www.mail-archive.com/mav-user%40lists.sourceforge.net/
--===============1546351342==--