Index: ITDynamic.php =================================================================== RCS file: /repository/pear/HTML_QuickForm/QuickForm/Renderer/ITDynamic.php,v retrieving revision 1.1 diff -u -r1.1 ITDynamic.php --- ITDynamic.php 9 Apr 2003 11:10:24 -0000 1.1 +++ ITDynamic.php 2 May 2003 21:14:50 -0000 @@ -153,10 +153,30 @@ $this->_tpl->touchBlock($blockName . '_required'); } } + + // Prepare multiple labels + $labels = $element->getLabel(); + + if (is_array($labels)) { + $mainLabel = array_shift($labels); + } else { + $mainLabel = $labels; + } + // render the element itself with its label $this->_tpl->setVariable('qf_element', $element->toHtml()); if ($this->_tpl->placeholderExists('qf_label', $blockName)) { - $this->_tpl->setVariable('qf_label', $element->getLabel()); + $this->_tpl->setVariable('qf_label', $mainLabel); + } + + // Render any extra labels + if (is_array($labels)) { + foreach($labels as $key => $label) { + $thisKey = $key+2; + if ($this->_tpl->blockExists("qf_label_$thisKey")) { + $this->_tpl->setVariable("qf_label_$thisKey", $label); + } + } } $this->_tpl->parse($blockName); $this->_tpl->parseCurrentBlock();