Hi,
I am trying to make a view which display 5 fields so as to take upto
5 names as inputs from the user (and ultimately store after some
processing). My problem is that I am not able to display the fields as
an array.
For example, if this is what I use in view to add names:
========================================================================
foreach (array ('1','2','3','4','5') as $row)
{
echo $form->input("Model.$row][name", array('label'=>'Model
Name'.
$row));
}
========================================================================
The above code generated the following in HTML:
------------------------------------------------------------------------------------------------------------------------------------------------
<label for="Model1][name">Model Name1</label>
<input name="data[Model][1][name]" type="text" value="" id="Model1]
[name" />
------------------------------------------------------------------------------------------------------------------------------------------------
and so on... which us quite close to what I want but not correct. Note
the for= in label and id= in input.
Is there a proper way to have 3 dimensional fields in cakephp ( I am
using 1.2 )
TIA,
Rex
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---