Re: Another problem with grids and checkboxes
| From: | Henri Marc | Date: | Tue, 03 Aug 2004 12:08:24 +0000 |
| Subject: | Re: Another problem with grids and checkboxes | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-192532@lists.php.net to get a copy of this message | ||
Hello,
> > <td style="vertical-align: top;">1<input
> > name="grid[1][1]" value="1" type="checkbox"><br>
> > </td>
> [snip]
> > <td style="vertical-align: top;">1<input
> > name="grid[2][1]" value="1" type="checkbox"><br>
> > </td>
>
> Is there a reason you're sending a 1, 2 or 3 value
> with the checkboxes?
Well, I thought it was the good way to do.
It helps me to know which box has been checked (?).
Yes, because
> You already know what was checked by the keys of the
> $grid array. I'd
Yes, ok.
> <td style="vertical-align: top;">1<input
> name="grid[1][1]" value="1"
> type="checkbox"<?php if(isset($grid[1][1])){echo '
> checked';}?>><br></td>
I let the value as it was because I would need to
rename a few hundreds checkboxes :-/ but I had used
your test in PHP if (isset($grid... and it works fine.
In fact it was very simple. When I think the time I
tried to find a solution. Shame on me.
Ok, my excuse is that I'm just learning.
Thank you very much.
Vous manquez despace pour stocker vos mails ?
Yahoo! Mail vous offre GRATUITEMENT 100 Mo !
Créez votre Yahoo! Mail sur http://fr.benefits.yahoo.com/
Le nouveau Yahoo! Messenger est arrivé ! Découvrez toutes les nouveautés pour dialoguer
instantanément avec vos amis. A télécharger gratuitement sur http://fr.messenger.yahoo.com