Yii Framework Forum: Input array - Yii Framework Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Input array - Rate Topic: -----

#1 User is offline   Speeedfire 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 192
  • Joined: 02-March 12

Posted 27 March 2012 - 12:48 PM

Hi!

How to use array in input field?

This is my dropdown lis:

<?php echo $form->labelEx($model,'nap_'.$i); ?>
                <?php echo $form->dropDownList($model, 'nap_'.$i, $ora); ?>
		<?php echo $form->error($model,'nap_'.$i); ?>
                <?php echo $form->dropDownList($model, 'nap_'.$i, $perc); ?>
		<?php echo $form->error($model,'nap_'.$i); ?>


I use a row in table. When i replace 'nap_'.$i to 'nap_'.$i.'[]' generate this:
name="Hirdetes[nap_1][]"

but is dump this array not show all element.
0

#2 User is offline   R.K. 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 117
  • Joined: 20-September 10

Posted 27 March 2012 - 02:51 PM

try to use tabular forms
1

#3 User is offline   Speeedfire 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 192
  • Joined: 02-March 12

Posted 27 March 2012 - 03:13 PM

Thank you!
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users