hi,

>  Hoping someone can help me with this. I'm using cake 1.1.19. I have a
>  few optional check boxes in my form where a user can subscribe to
>  newsletters. Problem is, I must be doing something wrong. How can I
>  set it up where cake recognizes a checkbox group?

Unless I'm mistaken, by repeating the same item 'User/newsletters',
you'll only ever get back from the form the last item in your form, as
they overwrite each other.

take a look at a helper I wrote a while back here
http://cakeforge.org/snippet/detail.php?type=snippet&id=190 - or
consider moving to 1.2 version of cakephp as that has checkboxes built
in.

hth

jon

On 03/03/2008, Hanzgroove <[EMAIL PROTECTED]> wrote:
>
>  Hi All,
>

>  <ul>
>  <li><?php echo $html->checkbox('User/newsletters', null,
>  array('value'=>'ps2'));?> Playstation 2</li>
>  <li><?php echo $html->checkbox('User/newsletters', null,
>  array('value'=>'pc'));?> PC</li>
>  <li><?php echo $html->checkbox('User/newsletters', null,
>  array('value'=>'video'));?> Video Updates</li>
>  <li><?php echo $html->checkbox('User/newsletters', null,
>  array('value'=>'xbox'));?> XBox 360</li>
>  <li><?php echo $html->checkbox('User/newsletters', null,
>  array('value'=>'downloads'));?> Downloads</li>
>  <li><?php echo $html->checkbox('User/newsletters', null,
>  array('value'=>'week_spc'));?> Weekly Specials</li>
>  <li><?php echo $html->checkbox('User/newsletters', null,
>  array('value'=>'gamecube'));?> GameCube</li>
>  <li><?php echo $html->checkbox('User/newsletters', null,
>  array('value'=>'daily'));?> Daily Updates</li>
>  </ul>
>  >
>


-- 

jon bennett
w: http://www.jben.net/
iChat (AIM): jbendotnet Skype: jon-bennett

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to