Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Array of Checkboxes

Explorer ,
Apr 03, 2009 Apr 03, 2009
Hi,

I have an old PHP script that I am converting to coldfusion, I have an array of checkboxes which in PHP was created by adding square brackets. When I try this in CF I get Element ROOMS is undefined in FORM.

How do I create and access an array of checkboxes in CF?
571
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Apr 03, 2009 Apr 03, 2009
The simplest way to do check boxes is to give them all the same name and forget about arrays. When you submit the form, you will either have a list or nothing whatsoever.
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Apr 03, 2009 Apr 03, 2009
LATEST
Make sure you check for IsDefined in the event that the list is empty on the processing page, or else you will get an error.
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources