Ok, I'm new to the Zend Framework so excuse me if this is kinda ignorant.
Right now I have a form build built into a table and the table looks like
<table>
<tr>
<td><label><input>[Text]</td>
</tr>
<tr>
<td><label><input>[Text]</td>
</tr>
<tr>
<td><label><input>[Text]</td>
</tr>
</table>
Who ever built it initially left something for the people I am working for to desire. These same people want to now have basically have a layout that looks like..
<table>
<tr>
<td><label><input>[Text]</td>
</tr>
</table>
<table>
<tr>
<td><label><input>[Text]</td>
</tr>
<tr>
<td><label><input>[Text]</td>
</tr>
<tr>
<td><label><input>[Text]</td>
</tr>
</table>
the table is currently rolled out via a foreach statement as the fields are dynamic and are role based. Essentially the code spits out a full array of that forms elements, and the foreach builds it out. I understand that much about it. But my main question is, is there a way to break out of the table so to speak and then roll out another?
overall I'd like to in essence inject </tr></table><br><table>
in some how so I can have 2 distinct tables.
updated with loop I have to exclude some variables and some stuff like it as its part of a propietray work in progress so Im not allowed to post any code from it on the web so that said heres a minimal version, stripped of anything that may make it noticeable
$form = new form_TableForm(self::CHANGEPREFS);
$form->setAction($this->_helper->url('saveprefs'));
foreach ($defaults as $name => $value)
{
if ($name == 'xxx1' && (!xxx::eval('xxx','view') || $zzz)) continue;
if ($name == 'xxx2' && !xxx::eval('xxx','view')) continue;
if ($name == 'xxx3' && !xxx::eval('xxx','alerts')) continue;
if ($name == 'xxx4' && !xxx::eval('xxx','alerts')) continue;
$element = new Zend_Form_Element_Checkbox($name);
$element->setLabel($this->_helper->Literal->xxx($name));
if ($value) $element->setValue($value);
$element->setOptions(array(
'required' => false,
'fullrow' => true
));
$form->addElement($element);
//if($name == 'xxx5'){$form .= "</table><table>";}
//bad attempt at injection above
}
$form->addDisplayGroup(array('savebutton'), 'buttonsgroup', array('fullrow' => true));
return $form;