QuickForm + ITDynamic renderer: problem with required radio button

From: Date: Fri, 07 Mar 2008 14:12:13 +0000
Subject: QuickForm + ITDynamic renderer: problem with required radio button
Groups: php.pear.general 
Request: Send a blank email to pear-general+get-28612@lists.php.net to get a copy of this message
Hello, I'd need a hint using the ITDynamic renderer; I add a radio group with two $f->addElement('radio', 'name', ...) (with the same name, and a label only in the first addElement), then set a "required" rule on it; it shows like this: * label1 ( ) option1 *        ( ) option2 If the user doesn't check any option and submits the form, the error about the missing check is displayed under each option: * label1 ( ) option1              this field is required *        ( ) option2              this field is required This is the HTML template: <!-- BEGIN qf_radio --> <tr>   <td class="tab_standard">     <!-- BEGIN qf_element_required --><span style="color:#F00;">*</span>     {qf_label}   </td>   <td class="tab_standard">     {qf_element}<br />   </td> </tr> <!-- END qf_radio --> Is it possible to put the "required" sign (*) and the error near only one of the options? I'd like the "*" near the first, and the error under the second option... am I asking for too much? ;) Thanks, ciao      Cesare -- Cesare D'Amico | Gruppo Volta Area tecnica | Web & Mkt Solutions Tel: 045 21 000 84 | Via Leida 8 - Verona Fax: 045 21 000 85 | http://www.gruppovolta.it

« previous php.pear.general (#28612) next »