I still have:
input id=test type=checkbox name=test/
input id=test type=checkbox name=test/
input id=test type=checkbox name=test/
So I can't do that what I want in Symfony forms and I must use normal
forms ? :O
On 30 Gru, 08:59, DEEPAK BHATIA toreachdee...@gmail.com wrote:
Try this
Try this
$m = 1;
foreach ($this-getOption('param') as $i)
{
$temp = 'test'.$m;
$m = $m + 1;
$this-widgetSchema['comment'.$i['id']] = new
sfWidgetFormInputCheckbox(array(), array('name' = $temp));
}
On Wed, Dec 30, 2009 at 6:43 PM, dziobacz aaabbbcccda...@gmail.com
Now they have different names but they should have the same names and
different ID:
input id=test1 type=checkbox name=test1/
input id=test2 type=checkbox name=test2/
input id=test2 type=checkbox name=test3/
On 30 Gru, 14:34, DEEPAK BHATIA toreachdee...@gmail.com wrote:
Try this
$m = 1;
Try this
$m = 1;
foreach ($this-getOption('param') as $i)
{
$temp = 'test'.$m;
$temp1 = 'temp'.$m;
$m = $m + 1;
$this-widgetSchema['comment'.$i['id']] = new
sfWidgetFormInputCheckbox(array(), array('name' = $temp, 'id' =
$temp1));
}
On Wed, Dec 30, 2009 at
heh - again wrong :)
input id=temp1 type=checkbox name=test1/
input id=temp2 type=checkbox name=test2/
input id=temp3 type=checkbox name=test3/
On 30 Gru, 14:42, DEEPAK BHATIA toreachdee...@gmail.com wrote:
Try this
$m = 1;
foreach ($this-getOption('param') as $i)
{
$temp =
ok thx - now is ok - only 1 thing:
not: $temp = 'test'.$m;
but: $temp = 'test';
:)
On 30 Gru, 14:42, DEEPAK BHATIA toreachdee...@gmail.com wrote:
Try this
$m = 1;
foreach ($this-getOption('param') as $i)
{
$temp = 'test'.$m;
$temp1 = 'temp'.$m;
$m = $m + 1;
I guess this holds for radiobutton and not checkboxAre you want to it
for checkbox ?
Do you want to select one checkbox at a time ?
On Wed, Dec 30, 2009 at 7:09 PM, dziobacz aaabbbcccda...@gmail.com wrote:
Now they have different names but they should have the same names and
different ID:
Try this
$m = 1;
foreach ($this-getOption('param') as $i)
{
$temp = 'test'.$m;
$temp1 = 'temp';
$m = $m + 1;
$this-widgetSchema['comment'.$i['id']] = new
sfWidgetFormInputCheckbox(array(), array('name' = $temp, 'id' =$temp1));
}
On Wed, Dec 30, 2009 at 7:19 PM, dziobacz