[nycphp-talk] Quickform: Select All Checkboxes
Tom Melendez
tom at supertom.com
Tue Sep 20 11:43:16 EDT 2005
Hi Mike,
It's possible that you are asking the question of, "Does QF have
something built-in for this, or is there a 'Quickform' way of doing
this?". I use QF and am not familar with their way of handling this.
Instead, I just output a general javascript function that takes the name
of the checkbox array and whether to turn them all on or off. Since the
function is general, it doesn't care if there is one, or 1000. The html
for the selectall/clearall links and the extra javascript I just add to
the form with the 'html' element:
$form->addElement('html',$myhtmlstring);
If anyone knows a better way, I'm all ears.
Thanks,
Tom
http://www.liphp.org
Ray Lance wrote:
> It might help to notice that php runs on the webserver, whereas the
> select-all function would be wanted locally, on the browser client.
>
> ----- Original Message -----
> *From:* Nunez, Eddy <mailto:enunez at tiaa-cref.org>
> *To:* NYPHP Talk <mailto:talk at lists.nyphp.org>
> *Sent:* Tuesday, September 20, 2005 10:16 AM
> *Subject:* [work] Re: [nycphp-talk] Quickform: Select All Checkboxes
>
> Only way to implement a "(de)select all" at the browser level is
> with Javascript.
> Maybe QF has something built-in ... likely not since it's called
> "Quick" forms.
> As far as I know, PHP can't help you there.
>
> -Eddy
>
> -----Original Message-----
> *From:* talk-bounces at lists.nyphp.org
> <mailto:talk-bounces at lists.nyphp.org>
> [mailto:talk-bounces at lists.nyphp.org]*On Behalf Of *Mike Lynch
> *Sent:* Tuesday, September 20, 2005 4:56 AM
> *To:* talk at lists.nyphp.org
> *Subject:* [nycphp-talk] Quickform: Select All Checkboxes
>
> Hi All
>
> I am using QF to display a variable number of checkboxes
> (depends on what is returned from a database query).
> The number of "checkable" items can be quite large.
>
> What is the best way to implement a "Select All" and "Deselect
> All" option for these checkboxes in Quickform ?
>
> Thanks
>
> Mike
>
> |
>
> **************************************************************
> This message, including any attachments, contains confidential
> information intended for a specific individual and purpose, and is
> protected by law. If you are not the intended recipient, please
> contact sender immediately by reply e-mail and destroy all copies.
> You are hereby notified that any disclosure, copying, or
> distribution of this message, or the taking of any action based on
> it, is strictly prohibited.
> TIAA-CREF
> **************************************************************
> |
>
> ------------------------------------------------------------------------
> _______________________________________________
> New York PHP Talk Mailing List
> AMP Technology
> Supporting Apache, MySQL and PHP
> http://lists.nyphp.org/mailman/listinfo/talk
> http://www.nyphp.org
>
>------------------------------------------------------------------------
>
>_______________________________________________
>New York PHP Talk Mailing List
>AMP Technology
>Supporting Apache, MySQL and PHP
>http://lists.nyphp.org/mailman/listinfo/talk
>http://www.nyphp.org
>
>
More information about the talk
mailing list