5 Replies Latest reply on Dec 8, 2007 3:04 AM by Günter Schenk

    Insert multiple checkbox values

    Level 1
      Hello,
      I have a basic form with a number of areas that have multiple choice checkboxes. Checkboxes , meaning that one or 3 or none can be selected and they all share the same id/name but of course have differing values.

      I can not find anywhere in the ADDT that allows me to select the checkbox name when I do my insert. I want all the values of each individual checkbox name to be inserted into their respective fields.

      In the Insert transaction wizard I get three types of checkbox values (Yes or No, 1 or 0, or -1 or 0.

      None of those seem to relate to the common occurance of checkboxes with string values, all to be inserting into one specific table field.

      Is it possible or do I need to write some hand code to insert an array?

      Thanks in advance for any help rendered,

      Steve
        • 1. Re: Insert multiple checkbox values
          Günter Schenk Level 4
          Hi Steve,

          the closest approach I know of would be to apply ADDT´s Comma-separated Checkboxes widget to a regular text field, which will be rendered as multiple choice checkboxes. The checked values will be stored in whatever column you specify, all separated by comma.

          Cheers,
          Günter Schenk
          Adobe Community Expert, Dreamweaver
          • 2. Re: Insert multiple checkbox values
            Level 1
            Günter,
            Thank so much for the quick response. I'll give it a try.

            Regards,

            Steve
            • 3. Re: Insert multiple checkbox values
              Level 1
              Eeeeee.... Now that's an interesting widget.. You create a text field, but then need to create tables in your DB to pull the data to populate the checkbox fields that magically show up from the text field when rendered by the server.. Very interesting. Seems mine have formatting issues:
              http://www.peninsulaequipment.com/phoneAddy.php
              Only the "Screening Media" checkboxes are dynamically generated but for some reason they do not render left justified like the example shown here:
              http://help.adobe.com/en_US/Dreamweaver/9.0_ADDT/help.html?content=ch5_form_controls_33.ht ml#1028650

              Are there workarounds for the formatting problem or known reasons why it does not look like the example?
              • 4. Re: Insert multiple checkbox values
                Level 1
                I created a better example so as to isolate any conflicting elements:
                http://www.peninsulaequipment.com/test.php
                I have the justification working but the widget fails to accept the CSS assigned by either span or div. Both elements on the page are assigned the same css but only the lower text runs true.

                I suspect I have to now tear into the widget to see where the style is coming from and if/where there is a conflict.

                Good fun :)
                • 5. Re: Insert multiple checkbox values
                  Günter Schenk Level 4
                  Hi Steve,

                  ------
                  Only the "Screening Media" checkboxes are dynamically generated but for some reason they do not render left justified
                  ------

                  well, that´s to be expected when stuffing the whole body contents in a div align="center" container :-)

                  Cheers,
                  Günter Schenk
                  Adobe Community Expert, Dreamweaver