Checkbox Group Problem

mdfaraci 19 Sep, 2007
Please someone help.

I have been trying to trace a problem with Checkbox groups. The problem is when ever multiple values are selected only the last selected value shows up in submitted email. If i test the form outside of Joomla and ChronoForms it works as expected. IS there some limitation in the database structure for ChronosForms that will only hold one value for a checkbox name? and if so is there a work around

Thank you in advance
Max_admin 19 Sep, 2007
Hi Mdfaraci,

We had this problem before but has been fixed and well tested too many version ago, so we are sure all should be fine, please post this piece of your HTML code, I would like to look at it and give it a test.

Cheers

Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
mdfaraci 20 Sep, 2007
<p align="left"><strong><font face="Arial" color="#000000" 
size=2>Select the Special Interest Group 
Discussions you want:</font></strong></p>
        <p><input type="checkbox" value="Consortia General Discussion Group" name="Special_Interest_Group"> 
        Consortia General Discussion Group    
             </p>
        <p><input type="checkbox" value=" Large Scale Library Discussion Group " 
        name="Special_Interest_Group"> Large Scale Library Discussion Group </p>
        <p><input type="checkbox" value=" Law Library Discussion Group " 
        name="Special_Interest_Group"> Law Library Discussion Group </p>
        <p><input type="checkbox" value=" NT Discussion Group " 
        name="Special_Interest_Group"> NT Discussion Group </p>
        <p><input type="checkbox" value=" Public Library Discussion Group " 
        name="Special_Interest_Group"> Public Library Discussion Group </p>
        <p><input type="checkbox" value=" Special Library Discussion Group " 
        name="Special_Interest_Group"> Special Library Discussion Group 
      </p></font>
<br><br>Post edited by: admin, at: 2007/09/20 02:49
Max_admin 20 Sep, 2007
Right!! field names should be name="Special_Interest_Group[]", pay attention to the 2 brackets which are used to post the values as an array!

Cheers

Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
mdfaraci 20 Sep, 2007
Thank you Max for your help, but when i change to an array i get no value in email for that name. Sorry for being a newb, here is my code.

<p><input type="checkbox" name="Special_Interest_Group[]" 
        value="Consortia General Discussion Group"> 
        Consortia General Discussion Group    
             </p>
        <p><input type="checkbox" name="Special_Interest_Group[]" value="Large Scale Library Discussion Group"> Large Scale Library Discussion Group </p>
        <p><input type="checkbox" name="Special_Interest_Group[]" value="Law Library Discussion Group"> Law Library Discussion Group </p>
        <p><input type="checkbox" name="Special_Interest_Group[]" value="NT Discussion Group"> NT Discussion Group </p>
        <p><input type="checkbox" name="Special_Interest_Group[]" value="Public Library Discussion Group"> Public Library Discussion Group </p>
        <p><input type="checkbox" name="Special_Interest_Group[]" value="Special Library Discussion Group"> Special Library Discussion Group 
      </p>
<br><br>Post edited by: admin, at: 2007/09/20 20:36
Max_admin 21 Sep, 2007
Hi mdfaraci,

No worries, Ok, I gave this code a test here and both email and saved data are done 100% correct, could you please turn debug ON then send me a screenshot of the output after submitting the email ? there must be some setting wrong, and do you use the latest ChronoForms version ?

Cheers

Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
mdfaraci 21 Sep, 2007
Max not sure what i cleared out but i was playing around and set MySQL statement to Type instead of Engine, and it started working?? Now if i set it back to Type it still works. Any clarification on this or just one of those weird flukes. So the array thing did the trick u r awesome, thanks
Max_admin 21 Sep, 2007
Hi mdfaraci,

Thank you, but no clue why it did that, may be you changed something else ? coz the mysql type is regarding the mysql statement and won't affect data stored itself!!

Best regards,

Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Morlacheerful 23 Jul, 2008
Hi Admin,

i have the same problem as discribed here, but i am to stupid to fix it.
I have a group of Checkboxes, see here:
[code]<div>
<input name="broschuere[]&" type="checkbox" id="model_93_Sp_Li" value="Saab 9-3 Sport Limousine" style="border:none;">
<label style="width:200px" class="smalltext" for="model_93_Sp_Li">Saab 9-3 Sport Limousine</label>
GreyHead 23 Jul, 2008
Hi Helga,

Try
<input name="broschuere[]" . . . 
no '&'

Bob
Morlacheerful 23 Jul, 2008
Hi,
thanks for the reply,
but what about the code in the html template ist this
{broschuere[]}

??

Kind regards Helga
Max_admin 25 Jul, 2008

Hi,

thanks for the reply,

but what about the code in the html template ist this

{broschuere[]}


??



Kind regards Helga



No, remove the [] ->
{broschuere}


does the validation work now ?
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
This topic is locked and no more replies can be posted.